15 #include <sys/types.h>
52 gethostname(hostname, 64);
57 snprintf(suffix, 127,
".ls%08ld_host%s_pid%08d", fp.
lumi_, hostname, pid);
77 snprintf(rewrite, 128,
"\\1Run %ld/\\2/Run summary", fp.
run_);
79 store->save(tmp_root_fp,
81 "^(Reference/)?([^/]+)",
83 store->mtEnabled() ? fp.
run_ : 0,
93 std::ofstream meta_fd(tmp_meta_fp);
94 meta_fd << this->
fillOrigin(tmp_root_fp, root_fp);
97 checkError(
"Rename failed: ", root_fp, ::rename(tmp_root_fp.c_str(), root_fp.c_str()));
98 checkError(
"Rename failed: ", meta_fp, ::rename(tmp_meta_fp.c_str(), meta_fp.c_str()));
126 if (! f.
data.empty()) {
134 actual_msg += std::strerror(status);
143 desc.
setComment(
"Saves histograms from DQM store, online workflow.");
145 desc.
addUntracked<
int>(
"backupLumiCount", 10)->setComment(
146 "How often the backup file will be generated, in lumisections (-1 disables).");
150 descriptions.
add(
"saver", desc);
T getUntrackedParameter(std::string const &, T const &) const
void saveJobReport(const std::string &filename) const
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
#define DEFINE_FWK_MODULE(type)
virtual void saveRun(FileParameters fp) const
static const std::string fillOrigin(const std::string filename, const std::string final_filename)
static const std::string filename(FileParameters fp, bool useLumi=false)
void setComment(std::string const &value)
void appendSnapshot(SnapshotFiles new_snap) const
void checkError(const char *msg, const std::string file, int status) const
void logFileAction(const std::string &msg, const std::string &fileName) const
virtual void saveLumi(FileParameters fp) const
void makeSnapshot(const FileParameters &fp, bool final) const
std::list< SnapshotFiles > snapshots_
std::mutex snapshots_lock_
DQMStore::SaveReferenceTag saveReference_
void add(std::string const &label, ParameterSetDescription const &psetDescription)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
static void fillDescription(edm::ParameterSetDescription &d)
DQMFileSaverOnline(const edm::ParameterSet &ps)