#include <RevisionDML.h>
Classes | |
class | Entry |
class | HltEntry |
class | LumiEntry |
class | TrgEntry |
Public Member Functions | |
void | addEntry (coral::ISchema &schema, const std::string &datatableName, const Entry &entry, unsigned long long branch_id, const std::string &branchname) |
void | addRevision (coral::ISchema &schema, const std::string &datatableName, const Entry &revision, unsigned long long branch_id, std::string &branchname) |
void | bookNewEntry (coral::ISchema &schema, const std::string &datatableName, Entry &entry) |
void | bookNewRevision (coral::ISchema &schema, const std::string &datatableName, Entry &revision) |
unsigned long long | branchIdByName (coral::ISchema &schema, const std::string &branchName) |
unsigned long long | getEntryInBranchByName (coral::ISchema &schema, const std::string &datatableName, const std::string &entryname, const std::string &branchname) |
void | insertHltRunData (coral::ISchema &schema, const HltEntry &hltentry) |
void | insertLumiRunData (coral::ISchema &schema, const LumiEntry &lumientry) |
void | insertTrgRunData (coral::ISchema &schema, const TrgEntry &trgentry) |
Definition at line 9 of file RevisionDML.h.
void lumi::RevisionDML::addEntry | ( | coral::ISchema & | schema, |
const std::string & | datatableName, | ||
const Entry & | entry, | ||
unsigned long long | branch_id, | ||
const std::string & | branchname | ||
) |
Definition at line 61 of file RevisionDML.cc.
References lumi::RevisionDML::Entry::data_id, lumi::RevisionDML::Entry::entry_id, lumi::RevisionDML::Entry::entry_name, lumi::LumiNames::entryTableName(), nameDealer::entryTableName(), cmsPerfSuiteHarvest::now, lumi::RevisionDML::Entry::revision_id, lumi::LumiNames::revisionTableName(), lumi::LumiNames::revmapTableName(), and nameDealer::revmapTableName().
Referenced by lumi::Lumi2DB::writeAllLumiDataToSchema2(), lumi::HLTV32DB::writeHltDataToSchema2(), and lumi::TRGScalers2DB::writeTrgDataToSchema2().
void lumi::RevisionDML::addRevision | ( | coral::ISchema & | schema, |
const std::string & | datatableName, | ||
const Entry & | revision, | ||
unsigned long long | branch_id, | ||
std::string & | branchname | ||
) |
1.insert a new revision into the revisions table 2.insert into data_id, revision_id pair to datatable_revmap insert into revisions(revision_id,branch_id,branch_name,ctime) values() insert into datatable_rev(data_id,revision_id) values())
Definition at line 99 of file RevisionDML.cc.
References lumi::RevisionDML::Entry::data_id, cmsPerfSuiteHarvest::now, lumi::RevisionDML::Entry::revision_id, lumi::LumiNames::revisionTableName(), lumi::LumiNames::revmapTableName(), and nameDealer::revmapTableName().
Referenced by lumi::Lumi2DB::writeAllLumiDataToSchema2(), lumi::HLTV32DB::writeHltDataToSchema2(), and lumi::TRGScalers2DB::writeTrgDataToSchema2().
void lumi::RevisionDML::bookNewEntry | ( | coral::ISchema & | schema, |
const std::string & | datatableName, | ||
Entry & | entry | ||
) |
allocate new revision_id,entry_id,data_id
Definition at line 43 of file RevisionDML.cc.
References lumi::RevisionDML::Entry::data_id, lumi::RevisionDML::Entry::entry_id, lumi::LumiNames::entryTableName(), lumi::idDealer::generateNextIDForTable(), lumi::RevisionDML::Entry::revision_id, and lumi::LumiNames::revisionTableName().
Referenced by lumi::Lumi2DB::writeAllLumiDataToSchema2(), lumi::HLTV32DB::writeHltDataToSchema2(), and lumi::TRGScalers2DB::writeTrgDataToSchema2().
void lumi::RevisionDML::bookNewRevision | ( | coral::ISchema & | schema, |
const std::string & | datatableName, | ||
Entry & | revision | ||
) |
allocate new revision_id,data_id
Definition at line 53 of file RevisionDML.cc.
References lumi::RevisionDML::Entry::data_id, lumi::idDealer::generateNextIDForTable(), lumi::RevisionDML::Entry::revision_id, and lumi::LumiNames::revisionTableName().
Referenced by lumi::Lumi2DB::writeAllLumiDataToSchema2(), lumi::HLTV32DB::writeHltDataToSchema2(), and lumi::TRGScalers2DB::writeTrgDataToSchema2().
unsigned long long lumi::RevisionDML::branchIdByName | ( | coral::ISchema & | schema, |
const std::string & | branchName | ||
) |
select revision_id from revisions where name=:branchName
unsigned long long lumi::RevisionDML::getEntryInBranchByName | ( | coral::ISchema & | schema, |
const std::string & | datatableName, | ||
const std::string & | entryname, | ||
const std::string & | branchname | ||
) |
select e.entry_id from entrytabl e,revisiontable r where r.revision_id=e.revision_id and e.name=:entryname and r.branch_name=:branchname
Definition at line 14 of file RevisionDML.cc.
References lumi::LumiNames::entryTableName(), and lumi::LumiNames::revisionTableName().
Referenced by lumi::Lumi2DB::writeAllLumiDataToSchema2(), lumi::HLTV32DB::writeHltDataToSchema2(), and lumi::TRGScalers2DB::writeTrgDataToSchema2().
void lumi::RevisionDML::insertHltRunData | ( | coral::ISchema & | schema, |
const HltEntry & | hltentry | ||
) |
Definition at line 165 of file RevisionDML.cc.
References lumi::RevisionDML::Entry::data_id, lumi::RevisionDML::Entry::entry_id, lumi::RevisionDML::Entry::entry_name, lumi::LumiNames::hltdataTableName(), nameDealer::hltdataTableName(), dataDML::hltrundata, lumi::RevisionDML::HltEntry::npath, lumi::RevisionDML::HltEntry::pathnames, lumi::RevisionDML::HltEntry::runnumber, and lumi::RevisionDML::HltEntry::source.
Referenced by lumi::HLTV32DB::writeHltDataToSchema2().
void lumi::RevisionDML::insertLumiRunData | ( | coral::ISchema & | schema, |
const LumiEntry & | lumientry | ||
) |
Definition at line 123 of file RevisionDML.cc.
References lumi::RevisionDML::LumiEntry::bgev, lumi::RevisionDML::Entry::data_id, lumi::RevisionDML::Entry::entry_id, lumi::RevisionDML::Entry::entry_name, nameDealer::lumidataTableName(), lumi::LumiNames::lumidataTableName(), dataDML::lumirundata, lumi::RevisionDML::LumiEntry::ncollidingbunches, lumi::RevisionDML::LumiEntry::runnumber, and lumi::RevisionDML::LumiEntry::source.
Referenced by lumi::Lumi2DB::writeAllLumiDataToSchema2().
void lumi::RevisionDML::insertTrgRunData | ( | coral::ISchema & | schema, |
const TrgEntry & | trgentry | ||
) |
Definition at line 144 of file RevisionDML.cc.
References lumi::RevisionDML::TrgEntry::bitnames, lumi::RevisionDML::TrgEntry::bitzeroname, lumi::RevisionDML::Entry::data_id, lumi::RevisionDML::Entry::entry_id, lumi::RevisionDML::Entry::entry_name, lumi::RevisionDML::TrgEntry::runnumber, lumi::RevisionDML::TrgEntry::source, lumi::LumiNames::trgdataTableName(), nameDealer::trgdataTableName(), and dataDML::trgrundata.
Referenced by lumi::TRGScalers2DB::writeTrgDataToSchema2().