Implements popcon::PopConSourceHandler< EcalTPGLutIdMap >.
Definition at line 41 of file EcalTPGLutIdMapHandler.cc.
42 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"Started GetNewObjects!!!";
47 std::cout <<
"got offlineInfo = " << std::endl;
51 std::cout <<
" First object for this tag " << std::endl;
54 unsigned int max_since = 0;
55 max_since = static_cast<unsigned int>(
tagInfo().lastInterval.since);
56 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"max_since : " << max_since;
57 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"retrieved last payload ";
60 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"Retrieving run list from ONLINE DB ... ";
62 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"Making connection...";
93 if (min_run < max_since) {
94 min_run = max_since + 1;
101 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"min_run= " << min_run <<
"max_run= " << max_run;
107 std::vector<RunIOV> run_vec = my_list.
getRuns();
108 size_t num_runs = run_vec.size();
110 std::cout <<
"number of runs is : " << num_runs << std::endl;
114 for (
size_t kr = 0; kr < run_vec.size(); kr++) {
115 irun = static_cast<unsigned int>(run_vec[kr].
getRunNumber());
117 std::cout <<
" **************** " << std::endl;
118 std::cout <<
" **************** " << std::endl;
119 std::cout <<
" run= " << irun << std::endl;
122 std::map<EcalLogicID, RunTPGConfigDat>
dataset;
126 int the_config_version = 0;
128 std::map<EcalLogicID, RunTPGConfigDat>::const_iterator it;
141 std::cout <<
" run= " << irun <<
" tag " << the_config_tag <<
" version=" << the_config_version << std::endl;
146 std::cout <<
"the tag is different from last transferred run ... retrieving last config set from DB"
154 std::cout <<
" before fetch config set" << std::endl;
156 std::cout <<
" after fetch config set" << std::endl;
159 int lutId = fe_main_info.
getLUTId();
163 fe_lut_info.
setId(lutId);
165 std::map<EcalLogicID, FEConfigLUTGroupDat> dataset_TpgLut;
168 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"Got object!";
172 typedef std::map<EcalLogicID, FEConfigLUTGroupDat>::const_iterator CIfelut;
177 for (CIfelut
p = dataset_TpgLut.begin();
p != dataset_TpgLut.end();
p++) {
183 unsigned int lutArray[1024];
184 for (
int ilut = 0; ilut < 1024; ++ilut) {
203 writeFile(
"last_tpg_lutIdMap_settings.txt");
210 writeFile(
"last_tpg_lutIdMap_settings.txt");
212 std::cout <<
" even if the tag/version is not the same, the lutIdMap id is the same -> no transfer needed "
219 std::cout <<
"ERROR: THIS CONFIG DOES NOT EXIST: tag=" << the_config_tag <<
" version=" << the_config_version
224 std::cout <<
" **************** " << std::endl;
226 }
else if (
nr == 0) {
228 std::cout <<
" no tag saved to RUN_TPGCONFIG_DAT by EcalSupervisor -> no transfer needed " << std::endl;
229 std::cout <<
" **************** " << std::endl;
234 std::cout <<
" the tag/version is the same -> no transfer needed " << std::endl;
235 std::cout <<
" **************** " << std::endl;
236 writeFile(
"last_tpg_lutIdMap_settings.txt");
243 edm::LogInfo(
"EcalTPGLutIdMapHandler") <<
"Ecal - > end of getNewObjects -----------";
References gather_cfg::cout, writedatasetfile::dataset, MillePedeFileConverter_cfg::e, test_db_connect::econn, cppFunctionSkipper::exception, Exception, RunTPGConfigDat::getConfigTag(), FEConfigLUTGroupDat::getLUTGroupId(), FEConfigMainInfo::getLUTId(), FEConfigLUTGroupDat::getLUTValue(), DeadROCCounter::getRunNumber(), RunList::getRuns(), RunTPGConfigDat::getVersion(), test_db_connect::my_locdef, test_db_connect::my_rundef, EgHLTOffHistBins_cfi::nr, AlCaHLTBitMon_ParallelJobs::p, l1tpf_impl::readFromFile(), IODConfig::setConfigTag(), RunTag::setGeneralTag(), FEConfigLUTInfo::setId(), RunTag::setLocationDef(), EcalTPGLut::setLut(), RunTag::setRunTypeDef(), EcalTPGLutIdMap::setValue(), FEConfigMainInfo::setVersion(), findQualityFiles::size, AlCaHLTBitMon_QueryRunRegistry::string, and dumpRecoGeometry_cfg::tagInfo.