ATLAS Offline Software
AthenaPoolCnvSvc.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
10 #include "AthenaPoolCnvSvc.h"
11 
12 #include "GaudiKernel/AttribStringParser.h"
13 #include "GaudiKernel/ClassID.h"
14 #include "GaudiKernel/FileIncident.h"
15 #include "GaudiKernel/IIncidentSvc.h"
16 #include "GaudiKernel/IIoComponentMgr.h"
17 #include "GaudiKernel/IOpaqueAddress.h"
18 
23 
24 #include "StorageSvc/DbReflex.h"
25 #include "RootUtils/APRDefaults.h"
26 
27 #include <algorithm>
28 #include <charconv>
29 #include <format>
30 #include <iomanip>
31 #include <sstream>
32 
33 //______________________________________________________________________________
34 // Initialize the service.
36  // Initialize DataModelCompatSvc
37  ServiceHandle<IService> dmcsvc("DataModelCompatSvc", this->name());
38  ATH_CHECK(dmcsvc.retrieve());
39  // Retrieve PoolSvc
40  ATH_CHECK(m_poolSvc.retrieve());
41  // Retrieve ClassIDSvc
42  ATH_CHECK(m_clidSvc.retrieve());
43  // Register this service for 'I/O' events
44  ServiceHandle<IIoComponentMgr> iomgr("IoComponentMgr", name());
45  ATH_CHECK(iomgr.retrieve());
46  if (!iomgr->io_register(this).isSuccess()) {
47  ATH_MSG_FATAL("Could not register myself with the IoComponentMgr !");
48  return(StatusCode::FAILURE);
49  }
50  // Extracting MaxFileSizes for global default and map by Database name.
51  for (const auto& maxFileSizeSpec : m_maxFileSizes.value()) {
52  if (auto p = maxFileSizeSpec.find('='); p != std::string::npos) {
53  long long maxFileSize = 0;
54  const char* start = maxFileSizeSpec.data() + (p + 1);
55  const char* end = maxFileSizeSpec.data() + maxFileSizeSpec.size();
56  if (auto [ptr, ec] = std::from_chars(start, end, maxFileSize); ec != std::errc{}) {
57  ATH_MSG_WARNING(std::format("Invalid MaxFileSize value: {}", std::string(start, end)));
58  }
59  std::string databaseName = maxFileSizeSpec.substr(0, maxFileSizeSpec.find_first_of(" ="));
60  m_databaseMaxFileSize.emplace(std::move(databaseName), maxFileSize);
61  } else {
62  if (auto [ptr, ec] = std::from_chars(maxFileSizeSpec.data(), maxFileSizeSpec.data() + maxFileSizeSpec.size(), m_domainMaxFileSize); ec != std::errc{}) {
63  ATH_MSG_WARNING(std::format("Invalid MaxFileSize value: {}", maxFileSizeSpec));
64  }
65  }
66  }
67  // Validate provided event data technologies and fill the internal cache
68  for (const auto& [key, value] : m_storageTechProp.value()) {
69  try {
70  const auto dbType = pool::DbType::getType(value);
71  if (dbType == pool::TEST_StorageType) {
72  ATH_MSG_FATAL(std::format("Unknown storage type requested for file {}: {}", key, value));
73  return StatusCode::FAILURE;
74  }
75  m_storageTechMap.emplace(key, dbType.type());
76  } catch (const std::exception& e) {
77  ATH_MSG_FATAL(std::format("Exception while getting storage type for file {}: {}", key, e.what()));
78  return StatusCode::FAILURE;
79  } catch (...) {
80  ATH_MSG_FATAL(std::format("Unknown exception while getting storage type for file {}", key));
81  return StatusCode::FAILURE;
82  }
83  }
84  // Extracting INPUT POOL ItechnologySpecificAttributes for Domain, Database and Container.
86  // Extracting the INPUT POOL ItechnologySpecificAttributes which are to be printed for each event
88  // Setup incident for EndEvent to print out attributes each event
89  ServiceHandle<IIncidentSvc> incSvc("IncidentSvc", name());
90  long int pri = 1000;
91  if (!m_inputPoolAttrPerEvent.value().empty()) {
92  // Set to be listener for EndEvent
93  incSvc->addListener(this, "EndEvent", pri);
94  ATH_MSG_DEBUG("Subscribed to EndEvent for printing out input file attributes.");
95  }
96  if (!processPoolAttributes(m_inputAttr, "", IPoolSvc::kInputStream, false, true, true).isSuccess()) {
97  ATH_MSG_DEBUG("setInputAttribute failed setting POOL domain attributes.");
98  }
99 
100  // Load these dictionaries now, so we don't need to try to do so
101  // while multiple threads are running.
102  TClass::GetClass ("TLeafI");
103  TClass::GetClass ("TLeafL");
104  TClass::GetClass ("TLeafD");
105  TClass::GetClass ("TLeafF");
106 
107  return(StatusCode::SUCCESS);
108 }
109 //______________________________________________________________________________
111  ATH_MSG_DEBUG("I/O reinitialization...");
112  m_contextAttr.clear();
113  return(StatusCode::SUCCESS);
114 }
115 //______________________________________________________________________________
117  // Write remaining DataHeaderForms for a given streamName, "*"" means all
118  auto DHCnvListener = dynamic_cast<IIncidentListener*>( converter( ClassID_traits<DataHeader>::ID() ) );
119  FileIncident incident(name(), "WriteDataHeaderForms", streamName);
120  if( DHCnvListener ) DHCnvListener->handle(incident);
121 }
122 //______________________________________________________________________________
124  ATH_MSG_VERBOSE("stop()");
125  // In case of direct writing without an OutputStream, this should be a good time to flush DHForms
127  return StatusCode::SUCCESS;
128 }
129 //______________________________________________________________________________
131  ATH_MSG_VERBOSE("Finalizing...");
132  // Some algorithms write in finalize(), flush DHForms if any are left
134  // Release ClassIDSvc
135  if (!m_clidSvc.release().isSuccess()) {
136  ATH_MSG_WARNING("Cannot release ClassIDSvc.");
137  }
138  // Release PoolSvc
139  if (!m_poolSvc.release().isSuccess()) {
140  ATH_MSG_WARNING("Cannot release PoolSvc.");
141  }
142  // Print Performance Statistics
143  // The pattern AthenaPoolCnvSvc.*PerfStats is ignored in AtlasTest/TestTools/share/post.sh
144  const std::string msgPrefix{"PerfStats "};
145  ATH_MSG_INFO(msgPrefix << std::string(40, '-'));
146  ATH_MSG_INFO(msgPrefix << "Timing Measurements for AthenaPoolCnvSvc");
147  ATH_MSG_INFO(msgPrefix << std::string(40, '-'));
148  for(const auto& [key, value] : m_chronoMap) {
149  ATH_MSG_INFO(msgPrefix << "| " << std::left << std::setw(15) << key << " | "
150  << std::right << std::setw(15) << std::fixed << std::setprecision(0) << value << " ms |");
151  }
152  ATH_MSG_INFO(msgPrefix << std::string(40, '-'));
153 
154  m_cnvs.clear();
155  m_cnvs.shrink_to_fit();
156  return(StatusCode::SUCCESS);
157 }
158 //______________________________________________________________________________
160  ATH_MSG_DEBUG("I/O finalization...");
161  return(StatusCode::SUCCESS);
162 }
163 //______________________________________________________________________________
164 StatusCode AthenaPoolCnvSvc::createObj(IOpaqueAddress* pAddress, DataObject*& refpObject) {
165  assert(pAddress);
166  std::string objName = "ALL";
167  if (m_useDetailChronoStat.value()) {
168  if (m_clidSvc->getTypeNameOfID(pAddress->clID(), objName).isFailure()) {
169  objName = std::to_string(pAddress->clID());
170  }
171  objName += '#';
172  objName += *(pAddress->par() + 1);
173  }
174  // StopWatch listens from here until the end of this current scope
175  PMonUtils::BasicStopWatch stopWatch("cObj_" + objName, m_chronoMap);
176  if (!m_persSvcPerInputType.empty()) { // Use separate PersistencySvc for each input data type
177  TokenAddress* tokAddr = dynamic_cast<TokenAddress*>(pAddress);
178  if (tokAddr != nullptr && tokAddr->getToken() != nullptr && (tokAddr->getToken()->contID().starts_with(m_persSvcPerInputType.value() + "(") || tokAddr->getToken()->contID().starts_with(m_persSvcPerInputType.value() + "_"))) {
179  const unsigned int maxContext = m_poolSvc->getInputContextMap().size();
180  const unsigned int auxContext = m_poolSvc->getInputContext(tokAddr->getToken()->classID().toString() + tokAddr->getToken()->dbID().toString(), 1);
181  char text[32];
182  const std::string contextStr = std::format("[CTXT={:08X}]", auxContext);
183  std::strncpy(text, contextStr.c_str(), sizeof(text) - 1);
184  text[sizeof(text) - 1] = '\0';
185  if (m_poolSvc->getInputContextMap().size() > maxContext) {
186  if (m_poolSvc->setAttribute("TREE_CACHE", "0", pool::DbType(pool::ROOTTREE_StorageType).type(), "FID:" + tokAddr->getToken()->dbID().toString(), m_persSvcPerInputType.value(), auxContext).isSuccess()) {
187  ATH_MSG_DEBUG("setInputAttribute failed to switch off TTreeCache for id = " << auxContext << ".");
188  }
189  }
190  tokAddr->getToken()->setAuxString(text);
191  }
192  }
193  // Forward to base class createObj
194  StatusCode status = ::AthCnvSvc::createObj(pAddress, refpObject);
195  return(status);
196 }
197 //______________________________________________________________________________
198 StatusCode AthenaPoolCnvSvc::createRep(DataObject* pObject, IOpaqueAddress*& refpAddress) {
199  assert(pObject);
200  std::string objName = "ALL";
201  if (m_useDetailChronoStat.value()) {
202  if (m_clidSvc->getTypeNameOfID(pObject->clID(), objName).isFailure()) {
203  objName = std::to_string(pObject->clID());
204  }
205  objName += '#';
206  objName += pObject->registry()->name();
207  }
208  // StopWatch listens from here until the end of this current scope
209  PMonUtils::BasicStopWatch stopWatch("cRep_" + objName, m_chronoMap);
210  StatusCode status = StatusCode::FAILURE;
211  if (pObject->clID() == 1) {
212  // No transient object was found use cnv to write default persistent object
213  SG::DataProxy* proxy = dynamic_cast<SG::DataProxy*>(pObject->registry());
214  if (proxy != nullptr) {
215  IConverter* cnv = converter(proxy->clID());
216  status = cnv->createRep(pObject, refpAddress);
217  }
218  } else {
219  // Forward to base class createRep
220  try {
221  status = ::AthCnvSvc::createRep(pObject, refpAddress);
222  } catch(std::runtime_error& e) {
223  ATH_MSG_FATAL(e.what());
224  }
225  }
226  return(status);
227 }
228 //______________________________________________________________________________
229 StatusCode AthenaPoolCnvSvc::fillRepRefs(IOpaqueAddress* pAddress, DataObject* pObject) {
230  assert(pObject);
231  std::string objName = "ALL";
232  if (m_useDetailChronoStat.value()) {
233  if (m_clidSvc->getTypeNameOfID(pObject->clID(), objName).isFailure()) {
234  objName = std::to_string(pObject->clID());
235  }
236  objName += '#';
237  objName += pObject->registry()->name();
238  }
239  // StopWatch listens from here until the end of this current scope
240  PMonUtils::BasicStopWatch stopWatch("fRep_" + objName, m_chronoMap);
241  StatusCode status = StatusCode::FAILURE;
242  if (pObject->clID() == 1) {
243  // No transient object was found use cnv to write default persistent object
244  SG::DataProxy* proxy = dynamic_cast<SG::DataProxy*>(pObject->registry());
245  if (proxy != nullptr) {
246  IConverter* cnv = converter(proxy->clID());
247  status = cnv->fillRepRefs(pAddress, pObject);
248  }
249  } else {
250  // Forward to base class fillRepRefs
251  try {
252  status = ::AthCnvSvc::fillRepRefs(pAddress, pObject);
253  } catch(std::runtime_error& e) {
254  ATH_MSG_FATAL(e.what());
255  }
256  }
257  return(status);
258 }
259 //______________________________________________________________________________
260 StatusCode AthenaPoolCnvSvc::connectOutput(const std::string& outputConnectionSpec,
261  const std::string& /*openMode*/) {
262  return(connectOutput(outputConnectionSpec));
263 }
264 //______________________________________________________________________________
265 StatusCode AthenaPoolCnvSvc::connectOutput(const std::string& outputConnectionSpec) {
266 // This is called before DataObjects are being converted.
267  std::string outputConnection = outputConnectionSpec.substr(0, outputConnectionSpec.find('['));
268  // Extract the technology
269  int tech{0};
270  if (!decodeOutputSpec(outputConnection, tech).isSuccess()) {
271  ATH_MSG_ERROR("connectOutput FAILED extract file name and technology.");
272  return(StatusCode::FAILURE);
273  }
274  unsigned int contextId = outputContextId(outputConnection);
275  try {
276  if (!m_poolSvc->connect(pool::ITransaction::UPDATE, contextId).isSuccess()) {
277  ATH_MSG_ERROR("connectOutput FAILED to open an UPDATE transaction.");
278  return(StatusCode::FAILURE);
279  }
280  } catch (std::exception& e) {
281  ATH_MSG_ERROR("connectOutput - caught exception: " << e.what());
282  return(StatusCode::FAILURE);
283  }
284 
285  std::unique_lock<std::mutex> lock(m_mutex);
286  if (std::find(m_contextAttr.begin(), m_contextAttr.end(), contextId) == m_contextAttr.end()) {
287  std::size_t merge = outputConnection.find("?pmerge="); // Used to remove trailing TMemFile
288  int flush = m_numberEventsPerWrite.value();
289  m_contextAttr.push_back(contextId);
290  // Setting default 'TREE_MAX_SIZE' for ROOT to 1024 GB to avoid file chains.
291  std::vector<std::string> maxFileSize;
292  maxFileSize.push_back("TREE_MAX_SIZE");
293  maxFileSize.push_back("1099511627776L");
294  m_domainAttr.emplace_back(std::move(maxFileSize));
295  // Extracting OUTPUT POOL ItechnologySpecificAttributes for Domain, Database and Container.
297  //FIXME
298  for (auto& dbAttrEntry : m_databaseAttr) {
299  const std::string& opt = dbAttrEntry[0];
300  std::string& data = dbAttrEntry[1];
301  const std::string& file = dbAttrEntry[2];
302  const std::string& cont = dbAttrEntry[3];
303  std::size_t equal = cont.find('='); // Used to remove leading "TTree="
304  if (equal == std::string::npos) equal = 0;
305  else equal++;
306  std::size_t colon = m_containerPrefixProp.value().find(':');
307  if (colon == std::string::npos) colon = 0; // Used to remove leading technology
308  else colon++;
309  const auto& strProp = m_containerPrefixProp.value();
310  if (merge != std::string::npos && opt == "TREE_AUTO_FLUSH" && 0 == outputConnection.compare(0, merge, file) &&cont.compare(equal, std::string::npos, strProp, colon) == 0 && data != "int" && data != "DbLonglong" && data != "double" && data != "string") {
311  flush = atoi(data.c_str());
312  if (flush < 0 && m_numberEventsPerWrite.value() > 0) {
313  flush = m_numberEventsPerWrite.value();
315  } else if (flush > 0 && flush < m_numberEventsPerWrite.value()) {
316  flush = flush * (int(static_cast<float>(m_numberEventsPerWrite.value()) / flush - 0.5) + 1);
317  }
318  }
319  }
320  if (merge != std::string::npos) {
321  ATH_MSG_INFO("connectOutput setting auto write for: " << outputConnection << " to " << flush << " events");
322  m_fileFlushSetting[outputConnection.substr(0, merge)] = flush;
323  }
324  }
325  if (!processPoolAttributes(m_domainAttr, outputConnection, contextId).isSuccess()) {
326  ATH_MSG_DEBUG("connectOutput failed process POOL domain attributes.");
327  }
328  if (!processPoolAttributes(m_databaseAttr, outputConnection, contextId).isSuccess()) {
329  ATH_MSG_DEBUG("connectOutput failed process POOL database attributes.");
330  }
331  return(StatusCode::SUCCESS);
332 }
333 
334 //______________________________________________________________________________
335 StatusCode AthenaPoolCnvSvc::commitOutput(const std::string& outputConnectionSpec, bool doCommit) {
336  // This is called after all DataObjects are converted.
337  std::string outputConnection = outputConnectionSpec.substr(0, outputConnectionSpec.find('['));
338  // StopWatch listens from here until the end of this current scope
339  PMonUtils::BasicStopWatch stopWatch("commitOutput", m_chronoMap);
340  std::unique_lock<std::mutex> lock(m_mutex);
341  // Extract the technology
342  int tech{0};
343  if (!decodeOutputSpec(outputConnection, tech).isSuccess()) {
344  ATH_MSG_ERROR("connectOutput FAILED extract file name and technology.");
345  return(StatusCode::FAILURE);
346  }
347  unsigned int contextId = outputContextId(outputConnection);
348  if (!processPoolAttributes(m_domainAttr, outputConnection, contextId).isSuccess()) {
349  ATH_MSG_DEBUG("commitOutput failed process POOL domain attributes.");
350  }
351  if (!processPoolAttributes(m_databaseAttr, outputConnection, contextId).isSuccess()) {
352  ATH_MSG_DEBUG("commitOutput failed process POOL database attributes.");
353  }
354  if (!processPoolAttributes(m_containerAttr, outputConnection, contextId).isSuccess()) {
355  ATH_MSG_DEBUG("commitOutput failed process POOL container attributes.");
356  }
357  std::size_t merge = outputConnection.find("?pmerge="); // Used to remove trailing TMemFile
358  const std::string baseOutputConnection = outputConnection.substr(0, merge);
359  m_fileCommitCounter[baseOutputConnection]++;
360  if (merge != std::string::npos && m_fileFlushSetting[baseOutputConnection] > 0 && m_fileCommitCounter[baseOutputConnection] % m_fileFlushSetting[baseOutputConnection] == 0) {
361  doCommit = true;
362  ATH_MSG_DEBUG("commitOutput sending data.");
363  }
364 
365  // lock.unlock(); //MN: first need to make commitCache slot-specific
366  try {
367  if (doCommit) {
368  if (!m_poolSvc->commit(contextId).isSuccess()) {
369  ATH_MSG_ERROR("commitOutput FAILED to commit OutputStream.");
370  return(StatusCode::FAILURE);
371  }
372  } else {
373  if (!m_poolSvc->commitAndHold(contextId).isSuccess()) {
374  ATH_MSG_ERROR("commitOutput FAILED to commitAndHold OutputStream.");
375  return(StatusCode::FAILURE);
376  }
377  }
378  } catch (std::exception& e) {
379  ATH_MSG_ERROR("commitOutput - caught exception: " << e.what());
380  return(StatusCode::FAILURE);
381  }
382  if (!this->cleanUp(baseOutputConnection).isSuccess()) {
383  ATH_MSG_ERROR("commitOutput FAILED to cleanup converters.");
384  return(StatusCode::FAILURE);
385  }
386  // Check FileSize
387  long long int currentFileSize = m_poolSvc->getFileSize(outputConnection, tech, contextId);
388  if (m_databaseMaxFileSize.find(outputConnection) != m_databaseMaxFileSize.end()) {
389  if (currentFileSize > m_databaseMaxFileSize[outputConnection]) {
390  ATH_MSG_WARNING(std::format("FileSize {} > {} for {}", currentFileSize, m_databaseMaxFileSize[outputConnection], outputConnection));
391  return(StatusCode::RECOVERABLE);
392  }
393  } else if (currentFileSize > m_domainMaxFileSize) {
394  ATH_MSG_WARNING(std::format("FileSize {} > {} for {}", currentFileSize, m_domainMaxFileSize, outputConnection));
395  return(StatusCode::RECOVERABLE);
396  }
397  return(StatusCode::SUCCESS);
398 }
399 
400 //______________________________________________________________________________
401 StatusCode AthenaPoolCnvSvc::disconnectOutput(const std::string& outputConnectionSpec) {
402  std::string outputConnection = outputConnectionSpec.substr(0, outputConnectionSpec.find('['));
403  unsigned int contextId = outputContextId(outputConnection);
404  StatusCode sc = m_poolSvc->disconnect(contextId);
405  return sc;
406 }
407 
408 //______________________________________________________________________________
409 unsigned int AthenaPoolCnvSvc::outputContextId(const std::string& outputConnection) {
410  return m_persSvcPerOutput?
411  m_poolSvc->getOutputContext(outputConnection) : (unsigned int)IPoolSvc::kOutputStream;
412 }
413 
414 //______________________________________________________________________________
416  return(&*m_poolSvc);
417 }
418 //______________________________________________________________________________
419 Token* AthenaPoolCnvSvc::registerForWrite(Placement* placement, const void* obj, const RootType& classDesc) {
420  // StopWatch listens from here until the end of this current scope
421  PMonUtils::BasicStopWatch stopWatch("cRepR_ALL", m_chronoMap);
422  Token* token = nullptr;
423  if (m_persSvcPerOutput) { // Use separate PersistencySvc for each output stream/file
424  char text[32];
425  const std::string contextStr = std::format("[CTXT={:08X}]", m_poolSvc->getOutputContext(placement->fileName()));
426  std::strncpy(text, contextStr.c_str(), sizeof(text) - 1);
427  text[sizeof(text) - 1] = '\0';
428  placement->setAuxString(text);
429  }
430  token = m_poolSvc->registerForWrite(placement, obj, classDesc);
431  return(token);
432 }
433 //______________________________________________________________________________
434 void AthenaPoolCnvSvc::setObjPtr(void*& obj, const Token* token) {
435  ATH_MSG_VERBOSE("Requesting object for: " << token->toString());
436  // StopWatch listens from here until the end of this current scope
437  PMonUtils::BasicStopWatch stopWatch("cObjR_ALL", m_chronoMap);
438  if (token->dbID() != Guid::null()) {
439  ATH_MSG_VERBOSE("Requesting object for: " << token->toString());
440  m_poolSvc->setObjPtr(obj, token);
441  }
442 }
443 //______________________________________________________________________________
445  return(m_useDetailChronoStat.value());
446 }
447 //______________________________________________________________________________
449  const CLID& clid,
450  const std::string* par,
451  const unsigned long* ip,
452  IOpaqueAddress*& refpAddress) {
453  if( svcType != repSvcType() ) {
454  ATH_MSG_ERROR("createAddress: svcType != POOL_StorageType " << svcType << " " << repSvcType());
455  return(StatusCode::FAILURE);
456  }
457  std::unique_ptr<Token> token;
458  if (par[0].compare(0, 3, "SHM") == 0) {
459  token = std::make_unique<Token>();
460  token->setOid(Token::OID_t(ip[0], ip[1]));
461  token->setAuxString("[PNAME=" + par[2] + "]");
462  RootType classDesc = RootType::ByNameNoQuiet(par[2]);
463  token->setClassID(pool::DbReflex::guid(classDesc));
464  } else {
465  token.reset(m_poolSvc->getToken(par[0], par[1], ip[0]));
466  }
467  if (token == nullptr) {
468  return(StatusCode::RECOVERABLE);
469  }
470  refpAddress = new TokenAddress(repSvcType(), clid, "", par[1], IPoolSvc::kInputStream, std::move(token));
471  return(StatusCode::SUCCESS);
472 }
473 //______________________________________________________________________________
475  const CLID& clid,
476  const std::string& refAddress,
477  IOpaqueAddress*& refpAddress) {
478  if (svcType != repSvcType()) {
479  ATH_MSG_ERROR("createAddress: svcType != POOL_StorageType " << svcType << " " << repSvcType());
480  return(StatusCode::FAILURE);
481  }
482  refpAddress = new GenericAddress(repSvcType(), clid, refAddress);
483  return(StatusCode::SUCCESS);
484 }
485 //______________________________________________________________________________
486 StatusCode AthenaPoolCnvSvc::convertAddress(const IOpaqueAddress* pAddress,
487  std::string& refAddress) {
488  assert(pAddress);
489  const TokenAddress* tokAddr = dynamic_cast<const TokenAddress*>(pAddress);
490  if (tokAddr != nullptr && tokAddr->getToken() != nullptr) {
491  refAddress = tokAddr->getToken()->toString();
492  } else {
493  refAddress = *pAddress->par();
494  }
495  return(StatusCode::SUCCESS);
496 }
497 //__________________________________________________________________________
498 StatusCode AthenaPoolCnvSvc::decodeOutputSpec(std::string& fileSpec, int& outputTech) const {
499  if (fileSpec.starts_with ( "ROOTKEY:")) {
500  outputTech = pool::ROOTKEY_StorageType.type();
501  fileSpec.erase(0, 8);
502  } else if (fileSpec.starts_with ( "ROOTTREE:")) {
503  outputTech = pool::ROOTTREE_StorageType.type();
504  fileSpec.erase(0, 9);
505  } else if (fileSpec.starts_with ( "ROOTTREEINDEX:")) {
506  outputTech = pool::ROOTTREEINDEX_StorageType.type();
507  fileSpec.erase(0, 14);
508  } else if (fileSpec.starts_with ( "ROOTRNTUPLE:")) {
509  outputTech = pool::ROOTRNTUPLE_StorageType.type();
510  fileSpec.erase(0, 12);
511  } else if (outputTech == 0) {
512  // Extract the file name
513  std::string fileName{fileSpec};
514  if (auto pos = fileSpec.find("?pmerge="); pos != std::string::npos) {
515  fileName = fileSpec.substr(0, pos);
516  }
517  // Find the appropriate event data technology for this file
518  // This will be used for event data and its data header
519  // First we look for an exact file name match
520  // If that fails, we look for a wildcard ("*") match
521  // If that also fails, we use the hardcoded default value
522  if (auto it = m_storageTechMap.find(fileName); it != m_storageTechMap.end()) {
523  outputTech = it->second;
524  } else if (it = m_storageTechMap.find("*"); it != m_storageTechMap.end()) {
525  outputTech = it->second;
526  } else {
527  outputTech = pool::ROOTTREEINDEX_StorageType.type();
528  }
529  }
530  return StatusCode::SUCCESS;
531 }
532 //______________________________________________________________________________
534  m_cnvs.push_back(cnv);
535  return(StatusCode::SUCCESS);
536 }
537 //______________________________________________________________________________
538 StatusCode AthenaPoolCnvSvc::cleanUp(const std::string& connection) {
539  bool retError = false;
540  std::size_t cpos = connection.find(':');
541  std::size_t bpos = connection.find('[');
542  if (cpos == std::string::npos) {
543  cpos = 0;
544  } else {
545  cpos++;
546  }
547  if (bpos != std::string::npos) bpos = bpos - cpos;
548  const std::string conn = connection.substr(cpos, bpos);
549  ATH_MSG_VERBOSE("Cleanup for Connection='"<< conn <<"'");
550  for (auto converter : m_cnvs) {
551  if (!converter->cleanUp(conn).isSuccess()) {
552  ATH_MSG_WARNING("AthenaPoolConverter cleanUp failed.");
553  retError = true;
554  }
555  }
556  return(retError ? StatusCode::FAILURE : StatusCode::SUCCESS);
557 }
558 //______________________________________________________________________________
560  // Set attributes for input file
561  m_lastInputFileName = fileName; // Save file name for printing attributes per event
562  if (!processPoolAttributes(m_inputAttr, m_lastInputFileName, IPoolSvc::kInputStream, false, true, false).isSuccess()) {
563  ATH_MSG_DEBUG("setInputAttribute failed setting POOL database/container attributes.");
564  }
566  ATH_MSG_DEBUG("setInputAttribute failed getting POOL database/container attributes.");
567  }
568  if (!m_persSvcPerInputType.empty()) {
569  // Loop over all extra event input contexts and switch off TTreeCache
570  const auto& extraInputContextMap = m_poolSvc->getInputContextMap();
571  for (const auto& [label, id]: extraInputContextMap) {
572  if (m_poolSvc->setAttribute("TREE_CACHE", "0", pool::DbType(pool::ROOTTREE_StorageType).type(), m_lastInputFileName, m_persSvcPerInputType.value(), id).isSuccess()) {
573  ATH_MSG_DEBUG("setInputAttribute failed to switch off TTreeCache for = " << label << ".");
574  }
575  }
576  }
577  return(StatusCode::SUCCESS);
578 }
579 
580 //______________________________________________________________________________
581 void AthenaPoolCnvSvc::handle(const Incident& incident) {
582  if (incident.type() == "EndEvent") {
584  ATH_MSG_DEBUG("handle EndEvent failed process POOL database attributes.");
585  }
586  }
587 }
588 //______________________________________________________________________________
589 AthenaPoolCnvSvc::AthenaPoolCnvSvc(const std::string& name, ISvcLocator* pSvcLocator) :
590  base_class(name, pSvcLocator, pool::POOL_StorageType.type()) {
591 }
592 //__________________________________________________________________________
593 void AthenaPoolCnvSvc::extractPoolAttributes(const StringArrayProperty& property,
594  std::vector<std::vector<std::string> >* contAttr,
595  std::vector<std::vector<std::string> >* dbAttr,
596  std::vector<std::vector<std::string> >* domAttr) const {
597  std::vector<std::string> opt;
598  std::string attributeName, containerName, databaseName, valueString;
599  for (const auto& propertyValue : property.value()) {
600  opt.clear();
601  attributeName.clear();
602  containerName.clear();
603  databaseName.clear();
604  valueString.clear();
605  using Gaudi::Utils::AttribStringParser;
606  for (const AttribStringParser::Attrib& attrib : AttribStringParser (propertyValue)) {
607  const std::string tag = attrib.tag;
608  const std::string val = attrib.value;
609  if (tag == "DatabaseName") {
610  databaseName = val;
611  } else if (tag == "ContainerName") {
612  if (databaseName.empty()) {
613  databaseName = "*";
614  }
615  containerName = std::move(val);
616  } else {
617  attributeName = std::move(tag);
618  valueString = std::move(val);
619  }
620  }
621  if (!attributeName.empty() && !valueString.empty()) {
622  opt.push_back(attributeName);
623  opt.push_back(valueString);
624  if (!databaseName.empty()) {
625  opt.push_back(databaseName);
626  if (!containerName.empty()) {
627  opt.push_back(containerName);
628  if (containerName.compare(0, 6, "TTree=") == 0) {
629  dbAttr->push_back(opt);
630  } else {
631  contAttr->push_back(opt);
632  }
633  } else {
634  opt.push_back("");
635  dbAttr->push_back(opt);
636  }
637  } else if (domAttr != 0) {
638  domAttr->push_back(opt);
639  } else {
640  opt.push_back("*");
641  opt.push_back("");
642  dbAttr->push_back(opt);
643  }
644  }
645  }
646 }
647 //__________________________________________________________________________
648 StatusCode AthenaPoolCnvSvc::processPoolAttributes(std::vector<std::vector<std::string> >& attr,
649  const std::string& fileName,
650  unsigned long contextId,
651  bool doGet,
652  bool doSet,
653  bool doClear) const {
654  bool retError = false;
655  for (auto& attrEntry : attr) {
656  if (attrEntry.size() == 2) {
657  const std::string& opt = attrEntry[0];
658  std::string data = attrEntry[1];
659  if (data == "int" || data == "DbLonglong" || data == "double" || data == "string") {
660  if (doGet) {
661  if (!m_poolSvc->getAttribute(opt, data, pool::DbType(pool::ROOTTREE_StorageType).type(), contextId).isSuccess()) {
662  ATH_MSG_DEBUG("getAttribute failed for domain attr " << opt);
663  retError = true;
664  }
665  }
666  } else if (doSet) {
667  if (m_poolSvc->setAttribute(opt, data, pool::DbType(pool::ROOTTREE_StorageType).type(), contextId).isSuccess()) {
668  ATH_MSG_DEBUG("setAttribute " << opt << " to " << data);
669  if (doClear) {
670  attrEntry.clear();
671  }
672  } else {
673  ATH_MSG_DEBUG("setAttribute failed for domain attr " << opt << " to " << data);
674  retError = true;
675  }
676  }
677  }
678  if (attrEntry.size() == 4) {
679  const std::string& opt = attrEntry[0];
680  std::string data = attrEntry[1];
681  const std::string& file = attrEntry[2];
682  const std::string& cont = attrEntry[3];
683  if (!fileName.empty() && (0 == fileName.compare(0, fileName.find('?'), file)
684  || (file[0] == '*' && file.find("," + fileName + ",") == std::string::npos))) {
685  if (data == "int" || data == "DbLonglong" || data == "double" || data == "string") {
686  if (doGet) {
687  if (!m_poolSvc->getAttribute(opt, data, pool::DbType(pool::ROOTTREE_StorageType).type(), fileName, cont, contextId).isSuccess()) {
688  ATH_MSG_DEBUG("getAttribute failed for database/container attr " << opt);
689  retError = true;
690  }
691  }
692  } else if (doSet) {
693  if (m_poolSvc->setAttribute(opt, data, pool::DbType(pool::ROOTTREE_StorageType).type(), fileName, cont, contextId).isSuccess()) {
694  ATH_MSG_DEBUG("setAttribute " << opt << " to " << data << " for db: " << fileName << " and cont: " << cont);
695  if (doClear) {
696  if (file[0] == '*' && !m_persSvcPerOutput) {
697  attrEntry[2] += "," + fileName + ",";
698  } else {
699  attrEntry.clear();
700  }
701  }
702  } else {
703  ATH_MSG_DEBUG("setAttribute failed for " << opt << " to " << data << " for db: " << fileName << " and cont: " << cont);
704  retError = true;
705  }
706  }
707  }
708  }
709  }
710  std::erase_if(attr, [](const auto& entry) { return entry.empty(); });
711  return(retError ? StatusCode::FAILURE : StatusCode::SUCCESS);
712 }
AthenaPoolCnvSvc::m_poolSvc
ServiceHandle< IPoolSvc > m_poolSvc
Definition: AthenaPoolCnvSvc.h:176
AthenaPoolCnvSvc::m_contextAttr
std::vector< unsigned int > m_contextAttr
Definition: AthenaPoolCnvSvc.h:204
AthenaPoolCnvSvc::registerCleanUp
virtual StatusCode registerCleanUp(IAthenaPoolCleanUp *cnv) override
Implement registerCleanUp to register a IAthenaPoolCleanUp to be called during cleanUp.
Definition: AthenaPoolCnvSvc.cxx:533
AthenaPoolCnvSvc::createAddress
StatusCode createAddress(long svcType, const CLID &clid, const std::string *par, const unsigned long *ip, IOpaqueAddress *&refpAddress) override
Create a Generic address using explicit arguments to identify a single object.
Definition: AthenaPoolCnvSvc.cxx:448
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
IPoolSvc::kOutputStream
@ kOutputStream
Definition: IPoolSvc.h:39
AthenaPoolCnvSvc::cleanUp
virtual StatusCode cleanUp(const std::string &connection) override
Implement cleanUp to call all registered IAthenaPoolCleanUp cleanUp() function.
Definition: AthenaPoolCnvSvc.cxx:538
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
Amg::compare
std::pair< int, int > compare(const AmgSymMatrix(N) &m1, const AmgSymMatrix(N) &m2, double precision=1e-9, bool relative=false)
compare two matrices, returns the indices of the first element that fails the condition,...
Definition: EventPrimitivesHelpers.h:109
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
Placement
This class holds all the necessary information to guide the writing of an object in a physical place.
Definition: Placement.h:19
IPoolSvc
This class provides the interface to the LCG POOL persistency software.
Definition: IPoolSvc.h:35
checkCorrelInHIST.conn
conn
Definition: checkCorrelInHIST.py:25
TScopeAdapter::ByNameNoQuiet
static TScopeAdapter ByNameNoQuiet(const std::string &name, Bool_t load=kTRUE)
Definition: RootType.cxx:586
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:407
AthenaPoolCnvSvc::initialize
virtual StatusCode initialize() override
Required of all Gaudi Services.
Definition: AthenaPoolCnvSvc.cxx:35
DbReflex.h
pool::DbType::getType
static DbType getType(const std::string &name)
Access known storage type object by name.
AthenaPoolCnvSvc::outputContextId
unsigned outputContextId(const std::string &outputConnection)
Definition: AthenaPoolCnvSvc.cxx:409
vtune_athena.format
format
Definition: vtune_athena.py:14
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
AthenaPoolCnvSvc::m_clidSvc
ServiceHandle< IClassIDSvc > m_clidSvc
Definition: AthenaPoolCnvSvc.h:177
FullCPAlgorithmsTest_eljob.flush
flush
Definition: FullCPAlgorithmsTest_eljob.py:194
make_coralServer_rep.opt
opt
Definition: make_coralServer_rep.py:19
Token::contID
const std::string & contID() const
Access container identifier.
Definition: Token.h:69
AthenaPoolCnvSvc::m_numberEventsPerWrite
Gaudi::Property< int > m_numberEventsPerWrite
To use MetadataSvc to merge data placed in a certain container When using TMemFile call Write on numb...
Definition: AthenaPoolCnvSvc.h:233
mergePhysValFiles.start
start
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:13
AthenaPoolCnvSvc::m_domainMaxFileSize
long long m_domainMaxFileSize
Definition: AthenaPoolCnvSvc.h:217
pool
pool namespace
Definition: libname.h:15
AthenaPoolCnvSvc::m_inputAttrPerEvent
std::vector< std::vector< std::string > > m_inputAttrPerEvent
Definition: AthenaPoolCnvSvc.h:213
pool::ITransaction::UPDATE
@ UPDATE
Definition: ITransaction.h:30
skel.it
it
Definition: skel.GENtoEVGEN.py:407
AthenaPoolCnvSvc::decodeOutputSpec
virtual StatusCode decodeOutputSpec(std::string &connectionSpec, int &outputTech) const override
Extract/deduce the DB technology from the connection string/file specification.
Definition: AthenaPoolCnvSvc.cxx:498
Token::dbID
const Guid & dbID() const
Access database identifier.
Definition: Token.h:64
IAthenaPoolCleanUp
This class provides the interface for the AthenaPoolCleanUp which is used to clean up AthenaPoolConve...
Definition: IAthenaPoolCleanUp.h:19
AthenaPoolCnvSvc::m_databaseAttr
std::vector< std::vector< std::string > > m_databaseAttr
Definition: AthenaPoolCnvSvc.h:202
AthenaPoolCnvSvc::m_chronoMap
PMonUtils::BasicStopWatchResultMap_t m_chronoMap
Map that holds chrono information.
Definition: AthenaPoolCnvSvc.h:181
athena.value
value
Definition: athena.py:124
AthenaPoolCnvSvc::fillRepRefs
virtual StatusCode fillRepRefs(IOpaqueAddress *pAddress, DataObject *pObject) override
Implementation of IConversionSvc: Resolve the references of the converted object.
Definition: AthenaPoolCnvSvc.cxx:229
AthenaPoolCnvSvc::m_containerPrefixProp
Gaudi::Property< std::string > m_containerPrefixProp
POOL Container name prefix - will be part of or whole TTree/RNTuple name 'Default' takes the prefix f...
Definition: AthenaPoolCnvSvc.h:193
AthenaPoolCnvSvc::useDetailChronoStat
virtual bool useDetailChronoStat() const override
Definition: AthenaPoolCnvSvc.cxx:444
AthenaPoolCnvSvc::m_mutex
std::mutex m_mutex
Definition: AthenaPoolCnvSvc.h:229
AthenaPoolCnvSvc::m_maxFileSizes
Gaudi::Property< std::vector< std::string > > m_maxFileSizes
MaxFileSizes, vector with maximum file sizes for Athena POOL output files.
Definition: AthenaPoolCnvSvc.h:216
python.RatesEmulationExample.lock
lock
Definition: RatesEmulationExample.py:148
Token::classID
const Guid & classID() const
Access database identifier.
Definition: Token.h:73
AthenaPoolCnvSvc::setObjPtr
virtual void setObjPtr(void *&obj, const Token *token) override
Definition: AthenaPoolCnvSvc.cxx:434
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
MuonR4::to_string
std::string to_string(const SectorProjector proj)
Definition: MsTrackSeeder.cxx:66
Placement::setAuxString
Placement & setAuxString(const std::string &auxString)
Set auxiliary string.
Definition: Placement.h:42
AthenaPoolCnvSvc::AthenaPoolCnvSvc
AthenaPoolCnvSvc(const std::string &name, ISvcLocator *pSvcLocator)
Standard Service Constructor.
Definition: AthenaPoolCnvSvc.cxx:589
AthenaPoolCnvSvc::getPoolSvc
virtual IPoolSvc * getPoolSvc() override
Definition: AthenaPoolCnvSvc.cxx:415
AthenaPoolCnvSvc::processPoolAttributes
StatusCode processPoolAttributes(std::vector< std::vector< std::string > > &attr, const std::string &fileName, unsigned long contextId, bool doGet=true, bool doSet=true, bool doClear=true) const
Set/get technology dependent POOL attributes.
Definition: AthenaPoolCnvSvc.cxx:648
python.CaloAddPedShiftConfig.type
type
Definition: CaloAddPedShiftConfig.py:42
AthenaPoolCnvSvc::flushDataHeaderForms
void flushDataHeaderForms(const std::string &streamName="*")
Tell DataHeaderCnv to write out all DataHeaderForms for a given streamName (default is all)
Definition: AthenaPoolCnvSvc.cxx:116
AthenaPoolCnvSvc::m_fileFlushSetting
std::map< std::string, int > m_fileFlushSetting
Definition: AthenaPoolCnvSvc.h:206
AthenaPoolCnvSvc::io_reinit
virtual StatusCode io_reinit() override
Definition: AthenaPoolCnvSvc.cxx:110
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:92
pool::DbType::type
int type() const
Access to full type.
Definition: DbType.h:66
AthenaPoolCnvSvc::m_useDetailChronoStat
Gaudi::Property< bool > m_useDetailChronoStat
UseDetailChronoStat, enable detailed output for time and size statistics for AthenaPOOL: default = fa...
Definition: AthenaPoolCnvSvc.h:186
CxxUtils::fpcompare::equal
bool equal(double a, double b)
Compare two FP numbers, working around x87 precision issues.
Definition: fpcompare.h:114
PMonUtils::BasicStopWatch
Definition: BasicStopWatch.h:17
Token
This class provides a token that identifies in a unique way objects on the persistent storage.
Definition: Token.h:21
AthenaPoolCnvSvc::registerForWrite
virtual Token * registerForWrite(Placement *placement, const void *obj, const RootType &classDesc) override
Definition: AthenaPoolCnvSvc.cxx:419
AthenaPoolCnvSvc::createObj
virtual StatusCode createObj(IOpaqueAddress *pAddress, DataObject *&refpObject) override
Implementation of IConversionSvc: Create the transient representation of an object from persistent st...
Definition: AthenaPoolCnvSvc.cxx:164
TokenAddress
This class provides a Generic Transient Address for POOL tokens.
Definition: TokenAddress.h:23
Token::OID_t
Definition: Token.h:24
AthenaPoolCnvSvc::handle
virtual void handle(const Incident &incident) override
Implementation of IIncidentListener: Handle for EndEvent incidence.
Definition: AthenaPoolCnvSvc.cxx:581
Token::setClassID
Token & setClassID(const Guid &cl_id)
Access database identifier.
Definition: Token.h:75
IPoolSvc::kInputStream
@ kInputStream
Definition: IPoolSvc.h:39
Guid::toString
constexpr void toString(std::span< char, StrLen > buf, bool uppercase=true) const noexcept
Automatic conversion to string representation.
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:209
APRDefaults.h
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
pool::DbType
Definition: DbType.h:31
AthenaPoolCnvSvc::setInputAttributes
virtual StatusCode setInputAttributes(const std::string &fileName) override
Set the input file attributes, if any are requested from jobOpts.
Definition: AthenaPoolCnvSvc.cxx:559
AthenaPoolCnvSvc::finalize
virtual StatusCode finalize() override
Required of all Gaudi Services.
Definition: AthenaPoolCnvSvc.cxx:130
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
AthenaPoolCnvSvc::m_persSvcPerOutput
Gaudi::Property< bool > m_persSvcPerOutput
PersSvcPerOutput, boolean property to use multiple persistency services, one per output stream.
Definition: AthenaPoolCnvSvc.h:223
ClassID_traits
Default, invalid implementation of ClassID_traits.
Definition: Control/AthenaKernel/AthenaKernel/ClassID_traits.h:37
calibdata.exception
exception
Definition: calibdata.py:495
add-xsec-uncert-quadrature-N.label
label
Definition: add-xsec-uncert-quadrature-N.py:104
AthenaPoolCnvSvc.h
This file contains the class definition for the AthenaPoolCnvSvc class.
file
TFile * file
Definition: tile_monitor.h:29
AthenaPoolCnvSvc::m_inputAttr
std::vector< std::vector< std::string > > m_inputAttr
Definition: AthenaPoolCnvSvc.h:209
AthenaPoolCnvSvc::m_databaseMaxFileSize
std::map< std::string, long long > m_databaseMaxFileSize
Definition: AthenaPoolCnvSvc.h:218
find_tgc_unfilled_channelids.ip
ip
Definition: find_tgc_unfilled_channelids.py:3
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
Placement::fileName
const std::string & fileName() const
Access file name.
Definition: Placement.h:28
AthenaPoolCnvSvc::io_finalize
virtual StatusCode io_finalize() override
Definition: AthenaPoolCnvSvc.cxx:159
TokenAddress::getToken
Token * getToken()
Definition: TokenAddress.cxx:15
AthenaPoolCnvSvc::convertAddress
virtual StatusCode convertAddress(const IOpaqueAddress *pAddress, std::string &refAddress) override
Convert address to string form.
Definition: AthenaPoolCnvSvc.cxx:486
AthenaPoolCnvSvc::m_inputPoolAttrPerEvent
Gaudi::Property< std::vector< std::string > > m_inputPoolAttrPerEvent
Print input PoolAttributes per event, vector with names of technology specific attributes for POOL to...
Definition: AthenaPoolCnvSvc.h:212
AthenaPoolCnvSvc::m_poolAttr
Gaudi::Property< std::vector< std::string > > m_poolAttr
Output PoolAttributes, vector with names and values of technology specific attributes for POOL.
Definition: AthenaPoolCnvSvc.h:200
DataHeader.h
This file contains the class definition for the DataHeader and DataHeaderElement classes.
CLID
uint32_t CLID
The Class ID type.
Definition: Event/xAOD/xAODCore/xAODCore/ClassID_traits.h:47
AthenaPoolCnvSvc::disconnectOutput
virtual StatusCode disconnectOutput(const std::string &outputConnectionSpec) override
Disconnect to the output connection.
Definition: AthenaPoolCnvSvc.cxx:401
AthenaPoolCnvSvc::m_containerAttr
std::vector< std::vector< std::string > > m_containerAttr
Definition: AthenaPoolCnvSvc.h:203
AthenaPoolCnvSvc::extractPoolAttributes
void extractPoolAttributes(const Gaudi::Property< std::vector< std::string >> &property, std::vector< std::vector< std::string > > *contAttr, std::vector< std::vector< std::string > > *dbAttr, std::vector< std::vector< std::string > > *domAttr=0) const
Extract POOL ItechnologySpecificAttributes for Domain, Database and Container from property.
Definition: AthenaPoolCnvSvc.cxx:593
GetAllXsec.entry
list entry
Definition: GetAllXsec.py:132
AthenaPoolCnvSvc::commitOutput
virtual StatusCode commitOutput(const std::string &outputConnectionSpec, bool doCommit) override
Implementation of IConversionSvc: Commit pending output.
Definition: AthenaPoolCnvSvc.cxx:335
WriteHiveWithMetaData.streamName
string streamName
Definition: WriteHiveWithMetaData.py:23
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
createCoolChannelIdFile.par
par
Definition: createCoolChannelIdFile.py:28
AthenaPoolCnvSvc::m_inputPoolAttr
Gaudi::Property< std::vector< std::string > > m_inputPoolAttr
Input PoolAttributes, vector with names and values of technology specific attributes for POOL.
Definition: AthenaPoolCnvSvc.h:208
AthCnvSvc::createObj
virtual StatusCode createObj(IOpaqueAddress *pAddress, DataObject *&refpObject) override
Implementation of IConverter: Create the transient representation of an object.
Definition: AthCnvSvc.cxx:244
AthenaPoolCnvSvc::createRep
virtual StatusCode createRep(DataObject *pObject, IOpaqueAddress *&refpAddress) override
Implementation of IConversionSvc: Convert the transient object to the requested representation.
Definition: AthenaPoolCnvSvc.cxx:198
Token::toString
virtual const std::string toString() const
Retrieve the string representation of the token.
Definition: Token.cxx:134
Token::setOid
Token & setOid(const OID_t &oid)
Set object identifier.
Definition: Token.h:85
AthenaPoolCnvSvc::m_persSvcPerInputType
Gaudi::Property< std::string > m_persSvcPerInputType
PersSvcPerInputType, string property, tree name to use multiple persistency services,...
Definition: AthenaPoolCnvSvc.h:228
python.LumiBlobConversion.pos
pos
Definition: LumiBlobConversion.py:16
AthenaPoolCnvSvc::m_domainAttr
std::vector< std::vector< std::string > > m_domainAttr
Definition: AthenaPoolCnvSvc.h:201
Guid::null
static const Guid & null() noexcept
NULL-Guid: static class method.
Definition: Guid.cxx:14
AthenaPoolCnvSvc::m_fileCommitCounter
std::map< std::string, int > m_fileCommitCounter
Definition: AthenaPoolCnvSvc.h:205
TokenAddress.h
This file contains the class definition for the TokenAddress class.
python.CaloAddPedShiftConfig.int
int
Definition: CaloAddPedShiftConfig.py:45
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
Pythia8_RapidityOrderMPI.val
val
Definition: Pythia8_RapidityOrderMPI.py:14
Token::setAuxString
Token & setAuxString(const std::string &auxString)
Set auxiliary string.
Definition: Token.h:93
AthenaPoolCnvSvc::connectOutput
virtual StatusCode connectOutput(const std::string &outputConnectionSpec, const std::string &openMode) override
Implementation of IConversionSvc: Connect to the output connection specification with open mode.
Definition: AthenaPoolCnvSvc.cxx:260
AthCnvSvc::fillRepRefs
virtual StatusCode fillRepRefs(IOpaqueAddress *pAddress, DataObject *pObject) override
Implementation of IConverter: Resolve the references of the converted object.
Definition: AthCnvSvc.cxx:284
makeTransCanvas.text
text
Definition: makeTransCanvas.py:11
CxxUtils::atoi
int atoi(std::string_view str)
Helper functions to unpack numbers decoded in string into integers and doubles The strings are requir...
Definition: Control/CxxUtils/Root/StringUtils.cxx:85
merge.status
status
Definition: merge.py:16
AthenaPoolCnvSvc::stop
virtual StatusCode stop() override
Definition: AthenaPoolCnvSvc.cxx:123
CaloCondBlobAlgs_fillNoiseFromASCII.tag
string tag
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:23
jobOptions.fileName
fileName
Definition: jobOptions.SuperChic_ALP2.py:39
Placement.h
This file contains the class definition for the Placement class (migrated from POOL).
AthenaPoolCnvSvc::m_storageTechProp
Gaudi::Property< std::map< std::string, std::string > > m_storageTechProp
Default Storage Tech for containers (ROOTTREE, ROOTTREEINDEX, ROOTRNTUPLE)
Definition: AthenaPoolCnvSvc.h:189
python.PyAthena.obj
obj
Definition: PyAthena.py:132
SG::DataProxy
Definition: DataProxy.h:45
Token.h
This file contains the class definition for the Token class (migrated from POOL).
AthenaPoolCnvSvc::m_lastInputFileName
std::string m_lastInputFileName
decoded storage tech requested in "StorageTechnology" property
Definition: AthenaPoolCnvSvc.h:175
AthCnvSvc::createRep
virtual StatusCode createRep(DataObject *pObject, IOpaqueAddress *&refpAddress) override
Implementation of IConverter: Convert the transient object to the requested representation.
Definition: AthCnvSvc.cxx:276
merge
Definition: merge.py:1
AthenaPoolCnvSvc::m_storageTechMap
std::map< std::string, int > m_storageTechMap
Definition: AthenaPoolCnvSvc.h:190
ServiceHandle
Definition: ClusterMakerTool.h:37
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37
TScopeAdapter
Definition: RootType.h:119
pool::DbReflex::guid
static Guid guid(const TypeH &id)
Determine Guid (normalized string form) from reflection type.