Implements popcon::PopConSourceHandler< EcalTPGSlidingWindow >.
Definition at line 48 of file EcalTPGSlidingWindowHandler.cc.
49 edm::LogInfo(
"EcalTPGSlidingWindowHandler") <<
"Started GetNewObjects!!!";
54 std::cout <<
"got offlineInfo = " << std::endl;
58 std::cout <<
" First object for this tag " << std::endl;
61 unsigned int max_since = 0;
62 max_since = static_cast<unsigned int>(
tagInfo().lastInterval.since);
63 edm::LogInfo(
"EcalTPGSlidingWindowHandler") <<
"max_since : " << max_since;
64 edm::LogInfo(
"EcalTPGSlidingWindowHandler") <<
"retrieved last payload ";
68 edm::LogInfo(
"EcalTPGSlidingWindowHandler") <<
"Retrieving run list from ONLINE DB ... ";
70 edm::LogInfo(
"EcalTPGSlidingWindowHandler") <<
"Making connection...";
99 if (min_run < max_since) {
100 min_run = max_since + 1;
108 edm::LogInfo(
"EcalTPGSlidingWindowHandler") <<
"min_run= " << min_run <<
"max_run= " << max_run;
114 std::vector<RunIOV> run_vec = my_list.
getRuns();
115 size_t num_runs = run_vec.size();
117 std::cout <<
"number of runs is : " << num_runs << std::endl;
119 unsigned int irun = 0;
122 std::vector<EcalLogicID> my_StripEcalLogicId_EE;
123 my_StripEcalLogicId_EE =
125 std::cout <<
" GOT the logic ID for the EE trigger strips " << std::endl;
127 for (
size_t kr = 0; kr < run_vec.size(); kr++) {
128 irun = static_cast<unsigned int>(run_vec[kr].
getRunNumber());
130 std::cout <<
" **************** " << std::endl;
131 std::cout <<
" **************** " << std::endl;
132 std::cout <<
" run= " << irun << std::endl;
135 std::map<EcalLogicID, RunTPGConfigDat>
dataset;
139 int the_config_version = 0;
141 std::map<EcalLogicID, RunTPGConfigDat>::const_iterator it;
155 std::cout <<
" run= " << irun <<
" tag " << the_config_tag <<
" version=" << the_config_version << std::endl;
160 std::cout <<
"the tag is different from last transferred run ... retrieving last config set from DB"
168 std::cout <<
" before fetch config set" << std::endl;
170 std::cout <<
" after fetch config set" << std::endl;
173 int slidingId = fe_main_info.
getSliId();
177 fe_sli_info.
setId(slidingId);
179 std::map<EcalLogicID, FEConfigSlidingDat> dataset_TpgSli;
183 typedef std::map<EcalLogicID, FEConfigSlidingDat>::const_iterator CIfesli;
188 for (CIfesli
p = dataset_TpgSli.begin();
p != dataset_TpgSli.end();
p++) {
195 if (ecid_name ==
"EB_VFE") {
196 int sm = ecid_xt.
getID1();
205 unsigned int stripEBId = 303176 + (
tt - 1) * 64 + (
strip - 1) * 8 + (tcc - 37) * 8192;
210 }
else if (ecid_name ==
"ECAL_readout_strip") {
214 int id3 = ecid_xt.
getID3();
216 bool set_the_strip =
false;
218 for (
size_t istrip = 0; istrip < my_StripEcalLogicId_EE.size(); istrip++) {
219 if (!set_the_strip) {
220 if (my_StripEcalLogicId_EE[istrip].getID1() ==
id1 &&
221 my_StripEcalLogicId_EE[istrip].getID2() ==
id2 &&
222 my_StripEcalLogicId_EE[istrip].getID3() == id3) {
223 stripid = my_StripEcalLogicId_EE[istrip].getLogicID();
224 set_the_strip =
true;
234 std::cout <<
" these may be the additional towers TCC/TT " <<
id1 <<
"/" <<
id2 << std::endl;
249 writeFile(
"last_tpg_sliding_settings.txt");
256 writeFile(
"last_tpg_sliding_settings.txt");
259 <<
" even if the tag/version is not the same, the sliding windows id is the same -> no transfer needed "
263 std::cout <<
"ERROR: THIS CONFIG DOES NOT EXIST: tag=" << the_config_tag <<
" version=" << the_config_version
270 std::cout <<
" **************** " << std::endl;
272 }
else if (
nr == 0) {
274 std::cout <<
" no tag saved to RUN_TPGCONFIG_DAT by EcalSupervisor -> no transfer needed " << std::endl;
275 std::cout <<
" **************** " << std::endl;
280 std::cout <<
" the tag/version is the same -> no transfer needed " << std::endl;
281 std::cout <<
" **************** " << std::endl;
282 writeFile(
"last_tpg_sliding_settings.txt");
289 edm::LogInfo(
"EcalTPGSlidingWindowHandler") <<
"Ecal - > end of getNewObjects -----------";
References gather_cfg::cout, writedatasetfile::dataset, MillePedeFileConverter_cfg::e, test_db_connect::econn, cppFunctionSkipper::exception, Exception, RunTPGConfigDat::getConfigTag(), EcalLogicID::getID1(), EcalLogicID::getID2(), EcalLogicID::getID3(), EcalLogicID::getName(), DeadROCCounter::getRunNumber(), RunList::getRuns(), FEConfigSlidingDat::getSliding(), FEConfigMainInfo::getSliId(), RunTPGConfigDat::getVersion(), globals_cff::id1, globals_cff::id2, test_db_connect::my_locdef, test_db_connect::my_rundef, EgHLTOffHistBins_cfi::nr, AlCaHLTBitMon_ParallelJobs::p, l1tpf_impl::readFromFile(), IODConfig::setConfigTag(), RunTag::setGeneralTag(), FEConfigSlidingInfo::setId(), RunTag::setLocationDef(), RunTag::setRunTypeDef(), EcalTPGSlidingWindow::setValue(), FEConfigMainInfo::setVersion(), findQualityFiles::size, AlCaHLTBitMon_QueryRunRegistry::string, digitizers_cfi::strip, dumpRecoGeometry_cfg::tagInfo, and groupFilesInBlocks::tt.