CMS 3D CMS Logo

EvFDaqDirector.h
Go to the documentation of this file.
1 #ifndef EVENTFILTER_UTILTIES_PLUGINS_EVFDAQDIRECTOR
2 #define EVENTFILTER_UTILTIES_PLUGINS_EVFDAQDIRECTOR
3 
7 
10 
11 //std headers
12 #include <string>
13 #include <sstream>
14 #include <iomanip>
15 #include <vector>
16 #include <map>
17 #include <list>
18 #include <mutex>
19 
20 //system headers
21 #include <sys/stat.h>
22 #include <sys/file.h>
23 #include <fcntl.h>
24 #include <cerrno>
25 #include <cstring>
26 #include <cstdio>
27 
28 #include <tbb/concurrent_hash_map.h>
29 #include <boost/filesystem.hpp>
30 #include <boost/asio.hpp>
31 
32 class SystemBounds;
33 class GlobalContext;
34 class StreamID;
35 
36 struct InputFile;
37 struct InputChunk;
38 
39 namespace edm {
40  class PathsAndConsumesOfModulesBase;
41  class ProcessContext;
42 } // namespace edm
43 
44 namespace Json {
45  class Value;
46 }
47 
48 namespace jsoncollector {
49  class DataPointDefinition;
50 }
51 
52 namespace edm {
54 }
55 
56 namespace evf {
57 
59 
61 
63  public:
65 
68  void initRun();
69  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
70  void preallocate(edm::service::SystemBounds const& bounds);
72  void preBeginRun(edm::GlobalContext const& globalContext);
73  void postEndRun(edm::GlobalContext const& globalContext);
74  void preGlobalEndLumi(edm::GlobalContext const& globalContext);
75  void overrideRunNumber(unsigned int run) { run_ = run; }
79  bool useFileBroker() const { return useFileBroker_; }
80 
82  std::string getInputJsonFilePath(const unsigned int ls, const unsigned int index) const;
83  std::string getRawFilePath(const unsigned int ls, const unsigned int index) const;
84  std::string getOpenRawFilePath(const unsigned int ls, const unsigned int index) const;
85  std::string getOpenInputJsonFilePath(const unsigned int ls, const unsigned int index) const;
86  std::string getDatFilePath(const unsigned int ls, std::string const& stream) const;
87  std::string getOpenDatFilePath(const unsigned int ls, std::string const& stream) const;
88  std::string getOpenOutputJsonFilePath(const unsigned int ls, std::string const& stream) const;
89  std::string getOutputJsonFilePath(const unsigned int ls, std::string const& stream) const;
90  std::string getMergedDatFilePath(const unsigned int ls, std::string const& stream) const;
91  std::string getMergedDatChecksumFilePath(const unsigned int ls, std::string const& stream) const;
95  std::string getProtocolBufferHistogramFilePath(const unsigned int ls, std::string const& stream) const;
97  std::string getOpenRootHistogramFilePath(const unsigned int ls, std::string const& stream) const;
98  std::string getRootHistogramFilePath(const unsigned int ls, std::string const& stream) const;
99  std::string getMergedRootHistogramFilePath(const unsigned int ls, std::string const& stream) const;
100  std::string getEoLSFilePathOnBU(const unsigned int ls) const;
101  std::string getEoLSFilePathOnFU(const unsigned int ls) const;
102  std::string getBoLSFilePathOnFU(const unsigned int ls) const;
103  std::string getEoRFilePath() const;
106  std::string getRunOpenDirPath() const { return run_dir_ + "/open"; }
108  void removeFile(unsigned int ls, unsigned int index);
109  void removeFile(std::string);
110 
111  FileStatus updateFuLock(unsigned int& ls, std::string& nextFile, uint32_t& fsize, uint64_t& lockWaitTime);
113  unsigned int getRunNumber() const { return run_; }
114  void lockInitLock();
115  void unlockInitLock();
116  void setFMS(evf::FastMonitoringService* fms) { fms_ = fms; }
117  bool isSingleStreamThread() { return nStreams_ == 1 && nThreads_ == 1; }
118  void lockFULocal();
119  void unlockFULocal();
120  void lockFULocal2();
121  void unlockFULocal2();
122  void createBoLSFile(const uint32_t lumiSection, bool checkIfExists) const;
123  void createLumiSectionFiles(const uint32_t lumiSection,
124  const uint32_t currentLumiSection,
125  bool doCreateBoLS = true);
126  static int parseFRDFileHeader(std::string const& rawSourcePath,
127  int& rawFd,
128  uint16_t& rawHeaderSize,
129  uint32_t& lsFromHeader,
130  int32_t& eventsFromHeader,
131  int64_t& fileSizeFromHeader,
132  bool requireHeader,
133  bool retry,
134  bool closeFile);
135  int grabNextJsonFromRaw(std::string const& rawSourcePath,
136  int& rawFd,
137  uint16_t& rawHeaderSize,
138  int64_t& fileSizeFromHeader,
139  bool& fileFound,
140  uint32_t serverLS);
141  int grabNextJsonFile(std::string const& jsonSourcePath,
142  std::string const& rawSourcePath,
143  int64_t& fileSizeFromJson,
144  bool& fileFound);
145  int grabNextJsonFileAndUnlock(boost::filesystem::path const& jsonSourcePath);
146 
147  EvFDaqDirector::FileStatus contactFileBroker(unsigned int& serverHttpStatus,
148  bool& serverState,
149  uint32_t& serverLS,
150  uint32_t& closedServerLS,
151  std::string& nextFileJson,
152  std::string& nextFileRaw,
153  bool& rawHeader,
154  int maxLS);
155 
156  FileStatus getNextFromFileBroker(const unsigned int currentLumiSection,
157  unsigned int& ls,
158  std::string& nextFile,
159  int& rawFd,
160  uint16_t& rawHeaderSize,
161  int32_t& serverEventsInNewFile_,
162  int64_t& fileSize,
163  uint64_t& thisLockWaitTimeUs);
164  void createRunOpendirMaybe();
166  int readLastLSEntry(std::string const& file);
167  unsigned int getLumisectionToStart() const;
168  void setDeleteTracking(std::mutex* fileDeleteLock,
169  std::list<std::pair<int, std::unique_ptr<InputFile>>>* filesToDelete) {
170  fileDeleteLockPtr_ = fileDeleteLock;
171  filesToDeletePtr_ = filesToDelete;
172  }
174  void checkMergeTypePSet(edm::ProcessContext const& pc);
177  static struct flock make_flock(short type, short whence, off_t start, off_t len, pid_t pid);
178 
179  private:
180  bool bumpFile(unsigned int& ls, unsigned int& index, std::string& nextFile, uint32_t& fsize, int maxLS);
181  void openFULockfileStream(bool create);
182  std::string inputFileNameStem(const unsigned int ls, const unsigned int index) const;
183  std::string outputFileNameStem(const unsigned int ls, std::string const& stream) const;
184  std::string mergedFileNameStem(const unsigned int ls, std::string const& stream) const;
186  std::string eolsFileName(const unsigned int ls) const;
187  std::string eorFileName() const;
188  int getNFilesFromEoLS(std::string BUEoLSFile);
189 
192  unsigned int run_;
199  unsigned int fuLockPollInterval_;
206 
207  unsigned int startFromLS_ = 1;
208 
217 
223 
229 
231 
232  unsigned long previousFileSize_;
233 
234  struct flock bu_w_flk;
235  struct flock bu_r_flk;
236  struct flock bu_w_fulk;
237  struct flock bu_r_fulk;
238  struct flock fu_rw_flk;
239  struct flock fu_rw_fulk;
240 
242 
244  std::list<std::pair<int, std::unique_ptr<InputFile>>>* filesToDeletePtr_ = nullptr;
245 
246  pthread_mutex_t init_lock_ = PTHREAD_MUTEX_INITIALIZER;
247 
248  unsigned int nStreams_ = 0;
249  unsigned int nThreads_ = 0;
250 
251  bool readEolsDefinition_ = true;
252  unsigned int eolsNFilesIndex_ = 1;
255  unsigned int stop_ls_override_ = 0;
256 
257  std::shared_ptr<Json::Value> transferSystemJson_;
258  tbb::concurrent_hash_map<std::string, std::string> mergeTypeMap_;
259 
260  //values initialized in .cc file
261  static const std::vector<std::string> MergeTypeNames_;
262 
263  //json parser
265 
266  boost::asio::io_service io_service_;
267  std::unique_ptr<boost::asio::ip::tcp::resolver> resolver_;
268  std::unique_ptr<boost::asio::ip::tcp::resolver::query> query_;
269  std::unique_ptr<boost::asio::ip::tcp::resolver::iterator> endpoint_iterator_;
270  std::unique_ptr<boost::asio::ip::tcp::socket> socket_;
271  //boost::asio::io_context io_context_;
272  //tcp::resolver resolver_;
273  //tcp::resolver::results_type endpoints_;
274  };
275 } // namespace evf
276 
277 #endif
evf::EvFDaqDirector::getOpenOutputJsonFilePath
std::string getOpenOutputJsonFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:419
evf::EvFDaqDirector::preallocate
void preallocate(edm::service::SystemBounds const &bounds)
Definition: EvFDaqDirector.cc:314
evf::EvFDaqDirector::directorBU_
bool directorBU_
Definition: EvFDaqDirector.h:204
evf::EvFDaqDirector::previousFileSize_
unsigned long previousFileSize_
Definition: EvFDaqDirector.h:232
evf::EvFDaqDirector::requireTSPSet_
bool requireTSPSet_
Definition: EvFDaqDirector.h:201
evf::EvFDaqDirector::unlockFULocal2
void unlockFULocal2()
Definition: EvFDaqDirector.cc:893
evf::EvFDaqDirector::endpoint_iterator_
std::unique_ptr< boost::asio::ip::tcp::resolver::iterator > endpoint_iterator_
Definition: EvFDaqDirector.h:269
eostools.ls
def ls(path, rec=False)
Definition: eostools.py:349
evf::EvFDaqDirector::dirManager_
DirManager dirManager_
Definition: EvFDaqDirector.h:230
evf::EvFDaqDirector::overrideRunNumber
void overrideRunNumber(unsigned int run)
Definition: EvFDaqDirector.h:75
evf::EvFDaqDirector::createBoLSFile
void createBoLSFile(const uint32_t lumiSection, bool checkIfExists) const
Definition: EvFDaqDirector.cc:898
evf::EvFDaqDirector::fileBrokerKeepAlive_
bool fileBrokerKeepAlive_
Definition: EvFDaqDirector.h:197
evf::EvFDaqDirector::getRawFilePath
std::string getRawFilePath(const unsigned int ls, const unsigned int index) const
Definition: EvFDaqDirector.cc:399
evf::EvFDaqDirector::fulocal_rwlock_fd_
int fulocal_rwlock_fd_
Definition: EvFDaqDirector.h:221
start
Definition: start.py:1
evf::EvFDaqDirector::runEnded
Definition: EvFDaqDirector.h:64
evf::EvFDaqDirector::useFileBroker_
bool useFileBroker_
Definition: EvFDaqDirector.h:193
evf::EvFDaqDirector::init_lock_
pthread_mutex_t init_lock_
Definition: EvFDaqDirector.h:246
evf::EvFDaqDirector::getEoLSFilePathOnBU
std::string getEoLSFilePathOnBU(const unsigned int ls) const
Definition: EvFDaqDirector.cc:470
evf::EvFDaqDirector::filesToDeletePtr_
std::list< std::pair< int, std::unique_ptr< InputFile > > > * filesToDeletePtr_
Definition: EvFDaqDirector.h:244
evf::EvFDaqDirector::bu_r_fulk
struct flock bu_r_fulk
Definition: EvFDaqDirector.h:237
evf::EvFDaqDirector::getEoRFilePath
std::string getEoRFilePath() const
Definition: EvFDaqDirector.cc:482
evf::EvFDaqDirector::readEolsDefinition_
bool readEolsDefinition_
Definition: EvFDaqDirector.h:251
evf::EvFDaqDirector::mergeTypePset_
std::string mergeTypePset_
Definition: EvFDaqDirector.h:203
evf::EvFDaqDirector::bu_run_open_dir_
std::string bu_run_open_dir_
Definition: EvFDaqDirector.h:215
evf::EvFDaqDirector::eolsFileName
std::string eolsFileName(const unsigned int ls) const
evf::EvFDaqDirector::EvFDaqDirector
EvFDaqDirector(const edm::ParameterSet &pset, edm::ActivityRegistry &reg)
Definition: EvFDaqDirector.cc:40
evf::EvFDaqDirector::bu_w_fulk
struct flock bu_w_fulk
Definition: EvFDaqDirector.h:236
evf::EvFDaqDirector::bu_readlock_fd_
int bu_readlock_fd_
Definition: EvFDaqDirector.h:218
evf::EvFDaqDirector::nThreads_
unsigned int nThreads_
Definition: EvFDaqDirector.h:249
evf::EvFDaqDirector::getStreamMergeType
std::string getStreamMergeType(std::string const &stream, MergeType defaultType)
Definition: EvFDaqDirector.cc:1928
evf::EvFDaqDirector::updateFuLock
FileStatus updateFuLock(unsigned int &ls, std::string &nextFile, uint32_t &fsize, uint64_t &lockWaitTime)
Definition: EvFDaqDirector.cc:497
evf::EvFDaqDirector::getLumisectionToStart
unsigned int getLumisectionToStart() const
Definition: EvFDaqDirector.cc:1787
edm
HLT enums.
Definition: AlignableModifier.h:19
edm::ProcessContext
Definition: ProcessContext.h:27
evf::EvFDaqDirector::checkTransferSystemPSet
void checkTransferSystemPSet(edm::ProcessContext const &pc)
Definition: EvFDaqDirector.cc:1802
cms::cuda::stream
cudaStream_t stream
Definition: HistoContainer.h:57
evf::DirManager
Definition: DirManager.h:13
evf::EvFDaqDirector::make_flock
static struct flock make_flock(short type, short whence, off_t start, off_t len, pid_t pid)
Definition: EvFDaqDirector.cc:1948
evf::EvFDaqDirector::getRootHistogramFilePath
std::string getRootHistogramFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:462
evf::EvFDaqDirector::bu_writelock_fd_
int bu_writelock_fd_
Definition: EvFDaqDirector.h:219
evf::EvFDaqDirector::getProtocolBufferHistogramFilePath
std::string getProtocolBufferHistogramFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:448
evf::EvFDaqDirector::contactFileBroker
EvFDaqDirector::FileStatus contactFileBroker(unsigned int &serverHttpStatus, bool &serverState, uint32_t &serverLS, uint32_t &closedServerLS, std::string &nextFileJson, std::string &nextFileRaw, bool &rawHeader, int maxLS)
Definition: EvFDaqDirector.cc:1372
evf::EvFDaqDirector::getStreamDestinations
std::string getStreamDestinations(std::string const &stream) const
Definition: EvFDaqDirector.cc:1864
evf::EvFDaqDirector::eorFileName
std::string eorFileName() const
evf::EvFDaqDirector::tryInitializeFuLockFile
void tryInitializeFuLockFile()
Definition: EvFDaqDirector.cc:845
evf::EvFDaqDirector::io_service_
boost::asio::io_service io_service_
Definition: EvFDaqDirector.h:266
evf::EvFDaqDirector::lockInitLock
void lockInitLock()
Definition: EvFDaqDirector.cc:874
evf::EvFDaqDirector::stop_ls_override_
unsigned int stop_ls_override_
Definition: EvFDaqDirector.h:255
DirManager.h
evf::EvFDaqDirector::fileBrokerHost_
std::string fileBrokerHost_
Definition: EvFDaqDirector.h:195
evf::EvFDaqDirector::sameFile
Definition: EvFDaqDirector.h:64
evf::EvFDaqDirector::runAbort
Definition: EvFDaqDirector.h:64
beamerCreator.create
def create(alignables, pedeDump, additionalData, outputFile, config)
Definition: beamerCreator.py:44
evf::EvFDaqDirector::getOpenDatFilePath
std::string getOpenDatFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:415
evf::EvFDaqDirector::bu_r_flk
struct flock bu_r_flk
Definition: EvFDaqDirector.h:235
evf::EvFDaqDirector::getFFFParamsFilePathOnBU
std::string getFFFParamsFilePathOnBU() const
Definition: EvFDaqDirector.cc:486
evf::EvFDaqDirector::query_
std::unique_ptr< boost::asio::ip::tcp::resolver::query > query_
Definition: EvFDaqDirector.h:268
evf::EvFDaqDirector::baseRunDir
std::string & baseRunDir()
Definition: EvFDaqDirector.h:76
InputFile
Definition: FedRawDataInputSource.h:201
evf::EvFDaqDirector::getRunOpenDirPath
std::string getRunOpenDirPath() const
Definition: EvFDaqDirector.h:106
evf::EvFDaqDirector::inputFileNameStem
std::string inputFileNameStem(const unsigned int ls, const unsigned int index) const
evf::EvFDaqDirector::outputFileNameStem
std::string outputFileNameStem(const unsigned int ls, std::string const &stream) const
evf::EvFDaqDirector::getDatFilePath
std::string getDatFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:411
evf::EvFDaqDirector::buBaseRunDir
std::string & buBaseRunDir()
Definition: EvFDaqDirector.h:77
evf::EvFDaqDirector::preBeginJob
void preBeginJob(edm::PathsAndConsumesOfModulesBase const &, edm::ProcessContext const &)
Definition: EvFDaqDirector.cc:353
evf::EvFDaqDirector::getInitFilePath
std::string getInitFilePath(std::string const &stream) const
Definition: EvFDaqDirector.cc:439
ActivityRegistry.h
evf::EvFDaqDirector::openFULockfileStream
void openFULockfileStream(bool create)
Definition: EvFDaqDirector.cc:855
evf::EvFDaqDirector::bu_t_monitor_stream
FILE * bu_t_monitor_stream
Definition: EvFDaqDirector.h:228
evf::FastMonitoringService
Definition: FastMonitoringService.h:69
evf::EvFDaqDirector::getEoLSFilePathOnFU
std::string getEoLSFilePathOnFU(const unsigned int ls) const
Definition: EvFDaqDirector.cc:474
evf::EvFDaqDirector::stopFilePath_
std::string stopFilePath_
Definition: EvFDaqDirector.h:253
evf::MergeTypeJSNDATA
Definition: EvFDaqDirector.h:58
evf::EvFDaqDirector::isSingleStreamThread
bool isSingleStreamThread()
Definition: EvFDaqDirector.h:117
evf::EvFDaqDirector::parseFRDFileHeader
static int parseFRDFileHeader(std::string const &rawSourcePath, int &rawFd, uint16_t &rawHeaderSize, uint32_t &lsFromHeader, int32_t &eventsFromHeader, int64_t &fileSizeFromHeader, bool requireHeader, bool retry, bool closeFile)
Definition: EvFDaqDirector.cc:926
evf::EvFDaqDirector::getOpenInputJsonFilePath
std::string getOpenInputJsonFilePath(const unsigned int ls, const unsigned int index) const
Definition: EvFDaqDirector.cc:407
Json
JSON (JavaScript Object Notation).
Definition: EvFDaqDirector.h:44
evf::EvFDaqDirector::selectedTransferMode_
std::string selectedTransferMode_
Definition: EvFDaqDirector.h:202
InputChunk
Definition: FedRawDataInputSource.h:177
evf::EvFDaqDirector::fms_
evf::FastMonitoringService * fms_
Definition: EvFDaqDirector.h:241
edm::ActivityRegistry
Definition: ActivityRegistry.h:132
evf::EvFDaqDirector::noFile
Definition: EvFDaqDirector.h:64
evf::EvFDaqDirector::useFileBroker
bool useFileBroker() const
Definition: EvFDaqDirector.h:79
evf::EvFDaqDirector::getMergedProtocolBufferHistogramFilePath
std::string getMergedProtocolBufferHistogramFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:453
evf::EvFDaqDirector::run_
unsigned int run_
Definition: EvFDaqDirector.h:192
evf::EvFDaqDirector::outputAdler32Recheck
bool outputAdler32Recheck() const
Definition: EvFDaqDirector.h:107
mutex
static boost::mutex mutex
Definition: Proxy.cc:9
evf::EvFDaqDirector::eolsNFilesIndex_
unsigned int eolsNFilesIndex_
Definition: EvFDaqDirector.h:252
evf::MergeTypeDAT
Definition: EvFDaqDirector.h:58
evf::EvFDaqDirector::pid_
std::string pid_
Definition: EvFDaqDirector.h:212
evf::EvFDaqDirector::fileBrokerUseLocalLock_
bool fileBrokerUseLocalLock_
Definition: EvFDaqDirector.h:198
edm::ConfigurationDescriptions
Definition: ConfigurationDescriptions.h:28
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
evf::EvFDaqDirector::bu_w_monitor_stream
FILE * bu_w_monitor_stream
Definition: EvFDaqDirector.h:227
evf::EvFDaqDirector::MergeTypeNames_
static const std::vector< std::string > MergeTypeNames_
Definition: EvFDaqDirector.h:261
evf::EvFDaqDirector::fileDeleteLockPtr_
std::mutex * fileDeleteLockPtr_
Definition: EvFDaqDirector.h:243
evf::EvFDaqDirector::getOutputJsonFilePath
std::string getOutputJsonFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:423
evf::EvFDaqDirector::fulocal_rwlock_fd2_
int fulocal_rwlock_fd2_
Definition: EvFDaqDirector.h:222
edm::GlobalContext
Definition: GlobalContext.h:29
edm::service::SystemBounds
Definition: SystemBounds.h:29
edm::ParameterSet
Definition: ParameterSet.h:36
evf::EvFDaqDirector::preBeginRun
void preBeginRun(edm::GlobalContext const &globalContext)
Definition: EvFDaqDirector.cc:358
evf::EvFDaqDirector::fileBrokerPort_
std::string fileBrokerPort_
Definition: EvFDaqDirector.h:196
evf::EvFDaqDirector::getMergedDatChecksumFilePath
std::string getMergedDatChecksumFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:431
FFFNamingSchema.h
evf::EvFDaqDirector::getNextFromFileBroker
FileStatus getNextFromFileBroker(const unsigned int currentLumiSection, unsigned int &ls, std::string &nextFile, int &rawFd, uint16_t &rawHeaderSize, int32_t &serverEventsInNewFile_, int64_t &fileSize, uint64_t &thisLockWaitTimeUs)
Definition: EvFDaqDirector.cc:1635
evf::EvFDaqDirector::bumpFile
bool bumpFile(unsigned int &ls, unsigned int &index, std::string &nextFile, uint32_t &fsize, int maxLS)
Definition: EvFDaqDirector.cc:766
evf::EvFDaqDirector::~EvFDaqDirector
~EvFDaqDirector()
Definition: EvFDaqDirector.cc:295
evf::EvFDaqDirector::outputAdler32Recheck_
bool outputAdler32Recheck_
Definition: EvFDaqDirector.h:200
evf::EvFDaqDirector::mergeTypeMap_
tbb::concurrent_hash_map< std::string, std::string > mergeTypeMap_
Definition: EvFDaqDirector.h:258
evf::EvFDaqDirector::unlockFULocal
void unlockFULocal()
Definition: EvFDaqDirector.cc:883
evf::EvFDaqDirector::grabNextJsonFileAndUnlock
int grabNextJsonFileAndUnlock(boost::filesystem::path const &jsonSourcePath)
Definition: EvFDaqDirector.cc:1283
evf::EvFDaqDirector::getOpenInitFilePath
std::string getOpenInitFilePath(std::string const &stream) const
Definition: EvFDaqDirector.cc:435
evf::EvFDaqDirector::run_dir_
std::string run_dir_
Definition: EvFDaqDirector.h:213
FrontierConditions_GlobalTag_cff.file
file
Definition: FrontierConditions_GlobalTag_cff.py:13
evf::EvFDaqDirector::getMergedRootHistogramFilePath
std::string getMergedRootHistogramFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:466
evf::EvFDaqDirector::fuLockPollInterval_
unsigned int fuLockPollInterval_
Definition: EvFDaqDirector.h:199
evf::EvFDaqDirector::lockFULocal
void lockFULocal()
Definition: EvFDaqDirector.cc:878
evf::EvFDaqDirector::getOpenProtocolBufferHistogramFilePath
std::string getOpenProtocolBufferHistogramFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:443
evf::EvFDaqDirector
Definition: EvFDaqDirector.h:62
evf::EvFDaqDirector::bu_base_dir_
std::string bu_base_dir_
Definition: EvFDaqDirector.h:191
evf::EvFDaqDirector::findCurrentRunDir
std::string findCurrentRunDir()
Definition: EvFDaqDirector.h:81
evf::EvFDaqDirector::mergedFileNameStem
std::string mergedFileNameStem(const unsigned int ls, std::string const &stream) const
evf::EvFDaqDirector::createRunOpendirMaybe
void createRunOpendirMaybe()
Definition: EvFDaqDirector.cc:1763
evf::EvFDaqDirector::getEoRFilePathOnFU
std::string getEoRFilePathOnFU() const
Definition: EvFDaqDirector.cc:484
evf::EvFDaqDirector::newLumi
Definition: EvFDaqDirector.h:64
evf::EvFDaqDirector::fu_rw_fulk
struct flock fu_rw_fulk
Definition: EvFDaqDirector.h:239
evf::EvFDaqDirector::createLumiSectionFiles
void createLumiSectionFiles(const uint32_t lumiSection, const uint32_t currentLumiSection, bool doCreateBoLS=true)
Definition: EvFDaqDirector.cc:908
evf::EvFDaqDirector::hltSourceDirectory_
std::string hltSourceDirectory_
Definition: EvFDaqDirector.h:205
evf::EvFDaqDirector::startFromLS_
unsigned int startFromLS_
Definition: EvFDaqDirector.h:207
jsoncollector
Definition: DataPoint.h:26
evf::EvFDaqDirector::readLastLSEntry
int readLastLSEntry(std::string const &file)
Definition: EvFDaqDirector.cc:1773
jsoncollector::DataPointDefinition
Definition: DataPointDefinition.h:20
evf::EvFDaqDirector::getMergedDatFilePath
std::string getMergedDatFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:427
evf::EvFDaqDirector::fu_rw_flk
struct flock fu_rw_flk
Definition: EvFDaqDirector.h:238
evf::EvFDaqDirector::run_string_
std::string run_string_
Definition: EvFDaqDirector.h:210
evf::DirManager::findRunDir
std::string findRunDir(unsigned int)
Definition: DirManager.cc:42
type
type
Definition: HCALResponse.h:21
evf::EvFDaqDirector::socket_
std::unique_ptr< boost::asio::ip::tcp::socket > socket_
Definition: EvFDaqDirector.h:270
writedatasetfile.run
run
Definition: writedatasetfile.py:27
evf::EvFDaqDirector::createProcessingNotificationMaybe
void createProcessingNotificationMaybe() const
Definition: EvFDaqDirector.cc:1942
ConfigurationDescriptions
evf::EvFDaqDirector::initRun
void initRun()
Definition: EvFDaqDirector.cc:150
evf::MergeType
MergeType
Definition: EvFDaqDirector.h:58
edm::PathsAndConsumesOfModulesBase
Definition: PathsAndConsumesOfModulesBase.h:34
evf::EvFDaqDirector::getRunNumber
unsigned int getRunNumber() const
Definition: EvFDaqDirector.h:113
evf::EvFDaqDirector::bu_w_flk
struct flock bu_w_flk
Definition: EvFDaqDirector.h:234
evf::EvFDaqDirector::fulockfile_
std::string fulockfile_
Definition: EvFDaqDirector.h:216
evf::EvFDaqDirector::setFMS
void setFMS(evf::FastMonitoringService *fms)
Definition: EvFDaqDirector.h:116
evf
Definition: fillJson.h:27
evf::EvFDaqDirector::preGlobalEndLumi
void preGlobalEndLumi(edm::GlobalContext const &globalContext)
Definition: EvFDaqDirector.cc:377
evf::EvFDaqDirector::transferSystemJson_
std::shared_ptr< Json::Value > transferSystemJson_
Definition: EvFDaqDirector.h:257
evf::EvFDaqDirector::hostname_
std::string hostname_
Definition: EvFDaqDirector.h:209
evf::EvFDaqDirector::getInputJsonFilePath
std::string getInputJsonFilePath(const unsigned int ls, const unsigned int index) const
Definition: EvFDaqDirector.cc:395
evf::EvFDaqDirector::getOpenRootHistogramFilePath
std::string getOpenRootHistogramFilePath(const unsigned int ls, std::string const &stream) const
Definition: EvFDaqDirector.cc:458
evf::EvFDaqDirector::dpd_
jsoncollector::DataPointDefinition * dpd_
Definition: EvFDaqDirector.h:264
evf::EvFDaqDirector::resolver_
std::unique_ptr< boost::asio::ip::tcp::resolver > resolver_
Definition: EvFDaqDirector.h:267
evf::EvFDaqDirector::removeFile
void removeFile(unsigned int ls, unsigned int index)
Definition: EvFDaqDirector.cc:495
evf::EvFDaqDirector::nStreams_
unsigned int nStreams_
Definition: EvFDaqDirector.h:248
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
evf::EvFDaqDirector::fu_readwritelock_fd_
int fu_readwritelock_fd_
Definition: EvFDaqDirector.h:220
SiStripCommissioningSource_FromEDM_cfg.FastMonitoringService
FastMonitoringService
Definition: SiStripCommissioningSource_FromEDM_cfg.py:49
cond::uint64_t
unsigned long long uint64_t
Definition: Time.h:13
evf::MergeTypeNULL
Definition: EvFDaqDirector.h:58
evf::EvFDaqDirector::bu_run_dir_
std::string bu_run_dir_
Definition: EvFDaqDirector.h:214
evf::EvFDaqDirector::buBaseRunOpenDir
std::string & buBaseRunOpenDir()
Definition: EvFDaqDirector.h:78
evf::EvFDaqDirector::getBoLSFilePathOnFU
std::string getBoLSFilePathOnFU(const unsigned int ls) const
Definition: EvFDaqDirector.cc:478
evf::EvFDaqDirector::base_dir_
std::string base_dir_
Definition: EvFDaqDirector.h:190
list
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger list("!*", "!HLTx*" if it matches 2 triggers or more) will accept the event if all the matching triggers are FAIL. It will reject the event if any of the triggers are PASS or EXCEPTION(this matches the behavior of "!*" before the partial wildcard feature was incorporated). Triggers which are in the READY state are completely ignored.(READY should never be returned since the trigger paths have been run
castor_dqm_sourceclient_file_cfg.path
path
Definition: castor_dqm_sourceclient_file_cfg.py:37
evf::EvFDaqDirector::fu_rw_lock_stream
FILE * fu_rw_lock_stream
Definition: EvFDaqDirector.h:226
ParameterSet.h
evf::EvFDaqDirector::getOpenRawFilePath
std::string getOpenRawFilePath(const unsigned int ls, const unsigned int index) const
Definition: EvFDaqDirector.cc:403
evf::EvFDaqDirector::stopFilePathPid_
std::string stopFilePathPid_
Definition: EvFDaqDirector.h:254
evf::EvFDaqDirector::initFileName
std::string initFileName(std::string const &stream) const
evf::EvFDaqDirector::unlockInitLock
void unlockInitLock()
Definition: EvFDaqDirector.cc:876
evf::EvFDaqDirector::run_nstring_
std::string run_nstring_
Definition: EvFDaqDirector.h:211
SystemBounds
evf::EvFDaqDirector::postEndRun
void postEndRun(edm::GlobalContext const &globalContext)
Definition: EvFDaqDirector.cc:368
evf::EvFDaqDirector::grabNextJsonFromRaw
int grabNextJsonFromRaw(std::string const &rawSourcePath, int &rawFd, uint16_t &rawHeaderSize, int64_t &fileSizeFromHeader, bool &fileFound, uint32_t serverLS)
Definition: EvFDaqDirector.cc:1022
evf::EvFDaqDirector::FileStatus
FileStatus
Definition: EvFDaqDirector.h:64
evf::EvFDaqDirector::lockFULocal2
void lockFULocal2()
Definition: EvFDaqDirector.cc:888
evf::EvFDaqDirector::grabNextJsonFile
int grabNextJsonFile(std::string const &jsonSourcePath, std::string const &rawSourcePath, int64_t &fileSizeFromJson, bool &fileFound)
Definition: EvFDaqDirector.cc:1103
RunID.h
evf::EvFDaqDirector::getNFilesFromEoLS
int getNFilesFromEoLS(std::string BUEoLSFile)
Definition: EvFDaqDirector.cc:705
evf::MergeTypePB
Definition: EvFDaqDirector.h:58
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27
Json::Value
Represents a JSON value.
Definition: value.h:99
evf::EvFDaqDirector::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
Definition: EvFDaqDirector.cc:321
evf::EvFDaqDirector::bu_w_lock_stream
FILE * bu_w_lock_stream
Definition: EvFDaqDirector.h:224
evf::EvFDaqDirector::fileBrokerHostFromCfg_
bool fileBrokerHostFromCfg_
Definition: EvFDaqDirector.h:194
evf::EvFDaqDirector::newFile
Definition: EvFDaqDirector.h:64
evf::EvFDaqDirector::bu_r_lock_stream
FILE * bu_r_lock_stream
Definition: EvFDaqDirector.h:225
evf::EvFDaqDirector::setDeleteTracking
void setDeleteTracking(std::mutex *fileDeleteLock, std::list< std::pair< int, std::unique_ptr< InputFile >>> *filesToDelete)
Definition: EvFDaqDirector.h:168
evf::EvFDaqDirector::checkMergeTypePSet
void checkMergeTypePSet(edm::ProcessContext const &pc)
Definition: EvFDaqDirector.cc:1910