CMS 3D CMS Logo

LHCInfoPerLSPopConAnalyzer.cc
Go to the documentation of this file.
9 #include "CoralBase/Attribute.h"
10 #include "CoralBase/AttributeList.h"
11 #include "CoralBase/AttributeSpecification.h"
12 #include "CoralBase/TimeStamp.h"
17 #include "RelationalAccess/ICursor.h"
18 #include "RelationalAccess/IQuery.h"
19 #include "RelationalAccess/ISchema.h"
20 #include "RelationalAccess/ISessionProxy.h"
21 #include <cmath>
22 #include <iostream>
23 #include <memory>
24 #include <sstream>
25 #include <sstream>
26 #include <string>
27 #include <utility>
28 #include <vector>
29 
31 
33 //define this as a plug-in
35 
37  bool comparePayloads(const LHCInfoPerLS& rhs, const LHCInfoPerLS& lhs) {
38  if (rhs.fillNumber() != lhs.fillNumber() || rhs.runNumber() != lhs.runNumber() ||
39  rhs.crossingAngleX() != lhs.crossingAngleX() || rhs.crossingAngleY() != lhs.crossingAngleY() ||
40  rhs.betaStarX() != lhs.betaStarX() || rhs.betaStarY() != lhs.betaStarY()) {
41  return false;
42  }
43  return true;
44  }
45 
46  size_t transferPayloads(const std::vector<std::pair<cond::Time_t, std::shared_ptr<LHCInfoPerLS>>>& buffer,
47  std::map<cond::Time_t, std::shared_ptr<LHCInfoPerLS>>& iovsToTransfer,
48  std::shared_ptr<LHCInfoPerLS>& prevPayload) {
49  size_t niovs = 0;
50  std::stringstream condIovs;
51  for (auto& iov : buffer) {
52  bool add = false;
53  auto payload = iov.second;
54  cond::Time_t since = iov.first;
55  if (iovsToTransfer.empty()) {
56  add = true;
57  } else {
58  LHCInfoPerLS& lastAdded = *iovsToTransfer.rbegin()->second;
59  if (!comparePayloads(lastAdded, *payload)) {
60  add = true;
61  }
62  }
63  if (add) {
64  niovs++;
65  condIovs << since << " ";
66  iovsToTransfer.insert(std::make_pair(since, payload));
67  prevPayload = iov.second;
68  }
69  }
70  edm::LogInfo("transferPayloads") << "TRANSFERED COND IOVS: " << condIovs.str();
71  return niovs;
72  }
73 
74 } // namespace theLHCInfoPerLSImpl
76 public:
78  : m_debug(pset.getUntrackedParameter<bool>("debug", false)),
79  m_startTime(),
80  m_endTime(),
81  m_samplingInterval((unsigned int)pset.getUntrackedParameter<unsigned int>("samplingInterval", 300)),
82  m_endFillMode(pset.getUntrackedParameter<bool>("endFill", true)),
83  m_name(pset.getUntrackedParameter<std::string>("name", "LHCInfoPerLSPopConSourceHandler")),
84  m_connectionString(pset.getUntrackedParameter<std::string>("connectionString", "")),
85  m_dipSchema(pset.getUntrackedParameter<std::string>("DIPSchema", "")),
86  m_authpath(pset.getUntrackedParameter<std::string>("authenticationPath", "")),
87  m_omsBaseUrl(pset.getUntrackedParameter<std::string>("omsBaseUrl", "")),
88  m_fillPayload(),
89  m_prevPayload(),
90  m_tmpBuffer() {
91  if (!pset.getUntrackedParameter<std::string>("startTime").empty()) {
92  m_startTime = boost::posix_time::time_from_string(pset.getUntrackedParameter<std::string>("startTime"));
93  }
94  boost::posix_time::ptime now = boost::posix_time::second_clock::local_time();
95  m_endTime = now;
96  if (!pset.getUntrackedParameter<std::string>("endTime").empty()) {
97  m_endTime = boost::posix_time::time_from_string(pset.getUntrackedParameter<std::string>("endTime"));
98  if (m_endTime > now)
99  m_endTime = now;
100  }
101  }
102  //L1: try with different m_dipSchema
103  //L2: try with different m_name
104  ~LHCInfoPerLSPopConSourceHandler() override = default;
105  void getNewObjects() override {
106  //if a new tag is created, transfer fake fill from 1 to the first fill for the first time
107  if (tagInfo().size == 0) {
108  edm::LogInfo(m_name) << "New tag " << tagInfo().name << "; from " << m_name << "::getNewObjects";
109  } else {
110  //check what is already inside the database
111  edm::LogInfo(m_name) << "got info for tag " << tagInfo().name << ": size " << tagInfo().size
112  << ", last object valid since " << tagInfo().lastInterval.since << " ( "
113  << boost::posix_time::to_iso_extended_string(
114  cond::time::to_boost(tagInfo().lastInterval.since))
115  << " ); from " << m_name << "::getNewObjects";
116  }
117 
118  cond::Time_t lastSince = tagInfo().lastInterval.since;
119  if (tagInfo().isEmpty()) {
120  // for a new or empty tag, an empty payload should be added on top with since=1
121  addEmptyPayload(1);
122  lastSince = 1;
123  } else {
124  edm::LogInfo(m_name) << "The last Iov in tag " << tagInfo().name << " valid since " << lastSince << "from "
125  << m_name << "::getNewObjects";
126  }
127 
128  boost::posix_time::ptime executionTime = boost::posix_time::second_clock::local_time();
129  cond::Time_t targetSince = 0;
130  cond::Time_t executionTimeIov = cond::time::from_boost(executionTime);
131  if (!m_startTime.is_not_a_date_time()) {
132  targetSince = cond::time::from_boost(m_startTime);
133  }
134  if (lastSince > targetSince)
135  targetSince = lastSince;
136 
137  edm::LogInfo(m_name) << "Starting sampling at "
138  << boost::posix_time::to_simple_string(cond::time::to_boost(targetSince));
139 
140  //retrieve the data from the relational database source
142  //configure the connection
143  if (m_debug) {
144  connection.setMessageVerbosity(coral::Debug);
145  } else {
146  connection.setMessageVerbosity(coral::Error);
147  }
148  connection.setAuthenticationPath(m_authpath);
149  connection.configure();
150  //create the sessions
151  cond::persistency::Session session = connection.createSession(m_connectionString, false);
152  // fetch last payload when available
153  if (!tagInfo().lastInterval.payloadId.empty()) {
155  session3.transaction().start(true);
157  session3.transaction().commit();
158 
159  // find startFillTime and endFillTime of the most recent fill already saved in the tag
160  if (m_prevPayload->fillNumber() != 0) {
161  cond::OMSService oms;
162  oms.connect(m_omsBaseUrl);
163  auto query = oms.query("fills");
164  query->addOutputVar("end_time");
165  query->filterEQ("fill_number", m_prevPayload->fillNumber());
166  bool foundFill = query->execute();
167  if (foundFill) {
168  auto result = query->result();
169 
170  if (!result.empty()) {
171  auto endFillTime = (*result.begin()).get<boost::posix_time::ptime>("end_time");
173  auto startFillTime = (*result.begin()).get<boost::posix_time::ptime>("start_time");
175  } else {
176  foundFill = false;
177  }
178  }
179  if (!foundFill) {
180  edm::LogError(m_name) << "Could not find end time of fill #" << m_prevPayload->fillNumber();
181  }
182  } else {
183  m_prevEndFillTime = 0;
185  }
186  }
187 
188  while (true) {
189  if (targetSince >= executionTimeIov) {
190  edm::LogInfo(m_name) << "Sampling ended at the time "
191  << boost::posix_time::to_simple_string(cond::time::to_boost(executionTimeIov));
192  break;
193  }
194  boost::posix_time::ptime targetTime = cond::time::to_boost(targetSince);
195  boost::posix_time::ptime startSampleTime;
196  boost::posix_time::ptime endSampleTime;
197 
198  cond::OMSService oms;
199  oms.connect(m_omsBaseUrl);
200  auto query = oms.query("fills");
201 
202  if (!m_endFillMode and m_prevPayload->fillNumber() and m_prevEndFillTime == 0ULL) {
203  // continue processing unfinished fill with some payloads already in the tag
204  edm::LogInfo(m_name) << "Searching started fill #" << m_prevPayload->fillNumber();
205  query->filterEQ("fill_number", m_prevPayload->fillNumber());
206  bool foundFill = query->execute();
207  if (foundFill)
208  foundFill = makeFillPayload(m_fillPayload, query->result());
209  if (!foundFill) {
210  edm::LogError(m_name) << "Could not find fill #" << m_prevPayload->fillNumber();
211  break;
212  }
213  startSampleTime = cond::time::to_boost(lastSince);
214  } else {
215  edm::LogInfo(m_name) << "Searching new fill after " << boost::posix_time::to_simple_string(targetTime);
216  query->filterNotNull("start_stable_beam").filterNotNull("fill_number");
217  if (targetTime > cond::time::to_boost(m_prevStartFillTime)) {
218  query->filterGE("start_time", targetTime);
219  } else {
220  query->filterGT("start_time", targetTime);
221  }
222 
223  query->filterLT("start_time", m_endTime);
224  if (m_endFillMode)
225  query->filterNotNull("end_time");
226  bool foundFill = query->execute();
227  if (foundFill)
228  foundFill = makeFillPayload(m_fillPayload, query->result());
229  if (!foundFill) {
230  edm::LogInfo(m_name) << "No fill found - END of job.";
231  break;
232  }
233  startSampleTime = cond::time::to_boost(m_startFillTime);
234  }
235 
236  unsigned short lhcFill = m_fillPayload->fillNumber();
237  bool ongoingFill = m_endFillTime == 0ULL;
238  if (ongoingFill) {
239  edm::LogInfo(m_name) << "Found ongoing fill " << lhcFill << " created at "
241  endSampleTime = executionTime;
242  targetSince = executionTimeIov;
243  } else {
244  edm::LogInfo(m_name) << "Found fill " << lhcFill << " created at " << cond::time::to_boost(m_startFillTime)
245  << " ending at " << cond::time::to_boost(m_endFillTime);
246  endSampleTime = cond::time::to_boost(m_endFillTime);
247  targetSince = m_endFillTime;
248  }
249 
250  if (m_endFillMode || ongoingFill) {
251  getLumiData(oms, lhcFill, startSampleTime, endSampleTime);
252 
253  if (!m_tmpBuffer.empty()) {
254  boost::posix_time::ptime flumiStart = cond::time::to_boost(m_tmpBuffer.front().first);
255  boost::posix_time::ptime flumiStop = cond::time::to_boost(m_tmpBuffer.back().first);
256  edm::LogInfo(m_name) << "First buffered lumi starts at " << flumiStart << " last lumi starts at "
257  << flumiStop;
258  session.transaction().start(true);
259  getCTTPSData(session, startSampleTime, endSampleTime);
260  session.transaction().commit();
261  }
262  }
263 
265  edm::LogInfo(m_name) << "Added " << niovs << " iovs within the Fill time";
266  if (niovs) {
269  }
270  m_tmpBuffer.clear();
271  if (m_prevPayload->fillNumber() and !ongoingFill)
273  }
274  }
275  std::string id() const override { return m_name; }
276 
277  static constexpr unsigned int kLumisectionsQueryLimit = 4000;
278 
279 private:
281  bool add = false;
282  if (m_iovs.empty()) {
283  if (!m_lastPayloadEmpty)
284  add = true;
285  } else {
286  auto lastAdded = m_iovs.rbegin()->second;
287  if (lastAdded->fillNumber() != 0) {
288  add = true;
289  }
290  }
291  if (add) {
292  auto newPayload = std::make_shared<LHCInfoPerLS>();
293  m_iovs.insert(std::make_pair(iov, newPayload));
294  m_prevPayload = newPayload;
295  m_prevEndFillTime = 0;
297  edm::LogInfo(m_name) << "Added empty payload with IOV" << iov << " ( "
298  << boost::posix_time::to_iso_extended_string(cond::time::to_boost(iov)) << " )";
299  }
300  }
301 
302  bool makeFillPayload(std::unique_ptr<LHCInfoPerLS>& targetPayload, const cond::OMSServiceResult& queryResult) {
303  bool ret = false;
304  if (!queryResult.empty()) {
305  auto row = *queryResult.begin();
306  auto currentFill = row.get<unsigned short>("fill_number");
307  m_startFillTime = cond::time::from_boost(row.get<boost::posix_time::ptime>("start_time"));
308  m_endFillTime = cond::time::from_boost(row.get<boost::posix_time::ptime>("end_time"));
309  targetPayload = std::make_unique<LHCInfoPerLS>();
310  targetPayload->setFillNumber(currentFill);
311  ret = true;
312  }
313  return ret;
314  }
315 
317  auto lumiTime = row.get<boost::posix_time::ptime>("start_time");
318  LHCInfoPerLS* thisLumiSectionInfo = new LHCInfoPerLS(*m_fillPayload);
319  m_tmpBuffer.emplace_back(std::make_pair(cond::time::from_boost(lumiTime), thisLumiSectionInfo));
320  }
321 
322  size_t bufferAllLS(const cond::OMSServiceResult& queryResult) {
323  for (auto r : queryResult) {
325  }
326  return queryResult.size();
327  }
328 
329  size_t bufferFirstStableBeamLS(const cond::OMSServiceResult& queryResult) {
330  for (auto r : queryResult) {
331  if (r.get<std::string>("beams_stable") == "true") {
333  edm::LogInfo(m_name) << "Buffered first lumisection of stable beam: LS: "
334  << r.get<std::string>("lumisection_number")
335  << " run: " << r.get<std::string>("run_number");
336  return 1;
337  }
338  }
339  return 0;
340  }
341 
342  size_t getLumiData(const cond::OMSService& oms,
343  unsigned short fillId,
344  const boost::posix_time::ptime& beginFillTime,
345  const boost::posix_time::ptime& endFillTime) {
346  auto query = oms.query("lumisections");
347  query->addOutputVars({"start_time", "run_number", "beams_stable", "lumisection_number"});
348  query->filterEQ("fill_number", fillId);
349  query->filterGT("start_time", beginFillTime).filterLT("start_time", endFillTime);
351  size_t nlumi = 0;
352  if (query->execute()) {
353  auto queryResult = query->result();
354  if (m_endFillMode) {
355  nlumi = bufferAllLS(queryResult);
356  } else if (!queryResult.empty()) {
357  auto newestPayload = queryResult.back();
358  if (newestPayload.get<std::string>("beams_stable") == "true") {
359  addPayloadToBuffer(newestPayload);
360  nlumi = 1;
361  edm::LogInfo(m_name) << "Buffered most recent lumisection:"
362  << " LS: " << newestPayload.get<std::string>("lumisection_number")
363  << " run: " << newestPayload.get<std::string>("run_number");
364  }
365  }
366  edm::LogInfo(m_name) << "Found " << queryResult.size() << " lumisections during the fill " << fillId;
367  } else {
368  edm::LogInfo(m_name) << "OMS query for lumisections of fill " << fillId << "failed, status:" << query->status();
369  }
370  return nlumi;
371  }
373  const boost::posix_time::ptime& beginFillTime,
374  const boost::posix_time::ptime& endFillTime) {
375  //run the fifth query against the CTPPS schema
376  //Initializing the CMS_CTP_CTPPS_COND schema.
377  coral::ISchema& CTPPS = session.coralSession().schema("CMS_PPS_SPECT_COND");
378  //execute query for CTPPS Data
379  std::unique_ptr<coral::IQuery> CTPPSDataQuery(CTPPS.newQuery());
380  //FROM clause
381  CTPPSDataQuery->addToTableList(std::string("PPS_LHC_MACHINE_PARAMS"));
382  //SELECT clause
383  CTPPSDataQuery->addToOutputList(std::string("DIP_UPDATE_TIME"));
384  CTPPSDataQuery->addToOutputList(std::string("LUMI_SECTION"));
385  CTPPSDataQuery->addToOutputList(std::string("RUN_NUMBER"));
386  CTPPSDataQuery->addToOutputList(std::string("XING_ANGLE_P5_X_URAD"));
387  CTPPSDataQuery->addToOutputList(std::string("XING_ANGLE_P5_Y_URAD"));
388  CTPPSDataQuery->addToOutputList(std::string("BETA_STAR_P5_X_M"));
389  CTPPSDataQuery->addToOutputList(std::string("BETA_STAR_P5_Y_M"));
390  //WHERE CLAUSE
391  coral::AttributeList CTPPSDataBindVariables;
392  CTPPSDataBindVariables.extend<coral::TimeStamp>(std::string("beginFillTime"));
393  CTPPSDataBindVariables.extend<coral::TimeStamp>(std::string("endFillTime"));
394  CTPPSDataBindVariables[std::string("beginFillTime")].data<coral::TimeStamp>() = coral::TimeStamp(beginFillTime);
395  CTPPSDataBindVariables[std::string("endFillTime")].data<coral::TimeStamp>() = coral::TimeStamp(endFillTime);
396  std::string conditionStr = std::string("DIP_UPDATE_TIME>= :beginFillTime and DIP_UPDATE_TIME< :endFillTime");
397  CTPPSDataQuery->setCondition(conditionStr, CTPPSDataBindVariables);
398  //ORDER BY clause
399  CTPPSDataQuery->addToOrderList(std::string("DIP_UPDATE_TIME"));
400  //define query output
401  coral::AttributeList CTPPSDataOutput;
402  CTPPSDataOutput.extend<coral::TimeStamp>(std::string("DIP_UPDATE_TIME"));
403  CTPPSDataOutput.extend<int>(std::string("LUMI_SECTION"));
404  CTPPSDataOutput.extend<int>(std::string("RUN_NUMBER"));
405  CTPPSDataOutput.extend<float>(std::string("XING_ANGLE_P5_X_URAD"));
406  CTPPSDataOutput.extend<float>(std::string("XING_ANGLE_P5_Y_URAD"));
407  CTPPSDataOutput.extend<float>(std::string("BETA_STAR_P5_X_M"));
408  CTPPSDataOutput.extend<float>(std::string("BETA_STAR_P5_Y_M"));
409  CTPPSDataQuery->defineOutput(CTPPSDataOutput);
410  //execute the query
411  coral::ICursor& CTPPSDataCursor = CTPPSDataQuery->execute();
412  cond::Time_t dipTime = 0;
413  unsigned int lumiSection = 0;
415  float crossingAngleX = 0., betaStarX = 0.;
416  float crossingAngleY = 0., betaStarY = 0.;
417 
418  bool ret = false;
420  while (CTPPSDataCursor.next()) {
421  if (m_debug) {
422  std::ostringstream CTPPS;
423  CTPPSDataCursor.currentRow().toOutputStream(CTPPS);
424  }
425  coral::Attribute const& dipTimeAttribute = CTPPSDataCursor.currentRow()[std::string("DIP_UPDATE_TIME")];
426  if (!dipTimeAttribute.isNull()) {
427  dipTime = cond::time::from_boost(dipTimeAttribute.data<coral::TimeStamp>().time());
428  if (filter.process(dipTime)) {
429  ret = true;
430  coral::Attribute const& lumiSectionAttribute = CTPPSDataCursor.currentRow()[std::string("LUMI_SECTION")];
431  if (!lumiSectionAttribute.isNull()) {
432  lumiSection = lumiSectionAttribute.data<int>();
433  }
434  coral::Attribute const& runNumberAttribute = CTPPSDataCursor.currentRow()[std::string("RUN_NUMBER")];
435  if (!runNumberAttribute.isNull()) {
436  runNumber = runNumberAttribute.data<int>();
437  }
438  coral::Attribute const& crossingAngleXAttribute =
439  CTPPSDataCursor.currentRow()[std::string("XING_ANGLE_P5_X_URAD")];
440  if (!crossingAngleXAttribute.isNull()) {
441  crossingAngleX = crossingAngleXAttribute.data<float>();
442  }
443  coral::Attribute const& crossingAngleYAttribute =
444  CTPPSDataCursor.currentRow()[std::string("XING_ANGLE_P5_Y_URAD")];
445  if (!crossingAngleYAttribute.isNull()) {
446  crossingAngleY = crossingAngleYAttribute.data<float>();
447  }
448  coral::Attribute const& betaStarXAttribute = CTPPSDataCursor.currentRow()[std::string("BETA_STAR_P5_X_M")];
449  if (!betaStarXAttribute.isNull()) {
450  betaStarX = betaStarXAttribute.data<float>();
451  }
452  coral::Attribute const& betaStarYAttribute = CTPPSDataCursor.currentRow()[std::string("BETA_STAR_P5_Y_M")];
453  if (!betaStarYAttribute.isNull()) {
454  betaStarY = betaStarYAttribute.data<float>();
455  }
456  for (auto it = filter.current(); it != m_tmpBuffer.end(); it++) {
457  // set the current values to all of the payloads of the lumi section samples after the current since
458  LHCInfoPerLS& payload = *(it->second);
459  payload.setCrossingAngleX(crossingAngleX);
460  payload.setCrossingAngleY(crossingAngleY);
461  payload.setBetaStarX(betaStarX);
462  payload.setBetaStarY(betaStarY);
463  payload.setLumiSection(lumiSection);
464  payload.setRunNumber(runNumber);
465  }
466  }
467  }
468  }
469  return ret;
470  }
471 
472 private:
473  bool m_debug;
474  // starting date for sampling
475  boost::posix_time::ptime m_startTime;
476  boost::posix_time::ptime m_endTime;
477  // sampling interval in seconds
478  unsigned int m_samplingInterval;
479  bool m_endFillMode = true;
481  //for reading from relational database source
485  std::unique_ptr<LHCInfoPerLS> m_fillPayload;
486  std::shared_ptr<LHCInfoPerLS> m_prevPayload;
491  std::vector<std::pair<cond::Time_t, std::shared_ptr<LHCInfoPerLS>>> m_tmpBuffer;
492  bool m_lastPayloadEmpty = false;
493 };
size
Write out results.
edm::ErrorSummaryEntry Error
bool makeFillPayload(std::unique_ptr< LHCInfoPerLS > &targetPayload, const cond::OMSServiceResult &queryResult)
cond::Time_t runNumber() const
Definition: LHCInfoPerLS.cc:23
Iov_t lastInterval
Definition: Types.h:73
std::unique_ptr< OMSServiceQuery > query(const std::string &function) const
Definition: OMSAccess.cc:129
T get(const std::string &attributeName)
Definition: OMSAccess.h:114
std::shared_ptr< LHCInfoPerLS > m_prevPayload
ret
prodAgent to be discontinued
void start(bool readOnly=true)
Definition: Session.cc:18
bool empty() const
Definition: OMSAccess.cc:69
~LHCInfoPerLSPopConSourceHandler() override=default
Time_t since
Definition: Types.h:53
size_t bufferFirstStableBeamLS(const cond::OMSServiceResult &queryResult)
LHCInfoPerLSPopConSourceHandler(edm::ParameterSet const &pset)
size_t size
Definition: Types.h:74
std::unique_ptr< T > fetchPayload(const cond::Hash &payloadHash)
Definition: Session.h:213
std::vector< std::pair< cond::Time_t, std::shared_ptr< LHCInfoPerLS > > > m_tmpBuffer
Log< level::Error, false > LogError
Transaction & transaction()
Definition: Session.cc:52
float const betaStarY() const
Definition: LHCInfoPerLS.cc:21
std::string name
Definition: Types.h:72
Definition: query.py:1
cond::TagInfo_t const & tagInfo() const
popcon::PopConAnalyzer< LHCInfoPerLSPopConSourceHandler > LHCInfoPerLSPopConAnalyzer
float const crossingAngleX() const
Definition: LHCInfoPerLS.cc:15
bool getCTTPSData(cond::persistency::Session &session, const boost::posix_time::ptime &beginFillTime, const boost::posix_time::ptime &endFillTime)
unsigned long long Time_t
Definition: Time.h:14
Time_t lumiTime(unsigned int run, unsigned int lumiId)
Definition: Time.cc:66
size_t bufferAllLS(const cond::OMSServiceResult &queryResult)
size_t transferPayloads(const std::vector< std::pair< cond::Time_t, std::shared_ptr< LHCInfoPerLS >>> &buffer, std::map< cond::Time_t, std::shared_ptr< LHCInfoPerLS >> &iovsToTransfer, std::shared_ptr< LHCInfoPerLS > &prevPayload)
Hash payloadId
Definition: Types.h:55
Session createSession(const std::string &connectionString, bool writeCapable=false)
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
void addPayloadToBuffer(cond::OMSServiceResultRef &row)
void setMessageVerbosity(coral::MsgLevel level)
Time_t from_boost(boost::posix_time::ptime bt)
float const crossingAngleY() const
Definition: LHCInfoPerLS.cc:17
Log< level::Info, false > LogInfo
cond::persistency::Session & dbSession() const
coral::ISessionProxy & coralSession()
Definition: Session.cc:218
void add(std::map< std::string, TH1 *> &h, TH1 *hist)
std::unique_ptr< LHCInfoPerLS > m_fillPayload
static constexpr unsigned int kLumisectionsQueryLimit
void connect(const std::string &baseUrl)
Definition: OMSAccess.cc:128
OMSServiceResultIterator begin() const
Definition: OMSAccess.cc:32
unsigned short const fillNumber() const
Definition: LHCInfoPerLS.cc:11
float const betaStarX() const
Definition: LHCInfoPerLS.cc:19
void setAuthenticationPath(const std::string &p)
const bool Debug
boost::posix_time::ptime to_boost(Time_t iValue)
bool comparePayloads(const LHCInfoPerLS &rhs, const LHCInfoPerLS &lhs)
size_t getLumiData(const cond::OMSService &oms, unsigned short fillId, const boost::posix_time::ptime &beginFillTime, const boost::posix_time::ptime &endFillTime)