![]() |
ATLAS Offline Software
|
This class provides the interface between Athena and PoolSvc. More...
#include <AthenaPoolCnvSvc.h>
Public Member Functions | |
| virtual StatusCode | initialize () override |
| Required of all Gaudi Services. | |
| virtual StatusCode | io_reinit () override |
| virtual StatusCode | finalize () override |
| Required of all Gaudi Services. | |
| virtual StatusCode | io_finalize () override |
| virtual StatusCode | stop () override |
| virtual StatusCode | createObj (IOpaqueAddress *pAddress, DataObject *&refpObject) override |
| Implementation of IConversionSvc: Create the transient representation of an object from persistent state. | |
| virtual StatusCode | createRep (DataObject *pObject, IOpaqueAddress *&refpAddress) override |
| Implementation of IConversionSvc: Convert the transient object to the requested representation. | |
| virtual StatusCode | fillRepRefs (IOpaqueAddress *pAddress, DataObject *pObject) override |
| Implementation of IConversionSvc: Resolve the references of the converted object. | |
| virtual StatusCode | connectOutput (const std::string &outputConnectionSpec, const std::string &openMode) override |
| Implementation of IConversionSvc: Connect to the output connection specification with open mode. | |
| virtual StatusCode | connectOutput (const std::string &outputConnectionSpec) override |
| Implementation of IConversionSvc: Connect to the output connection specification with open mode. | |
| virtual StatusCode | commitOutput (const std::string &outputConnectionSpec, bool doCommit) override |
| Implementation of IConversionSvc: Commit pending output. | |
| virtual StatusCode | disconnectOutput (const std::string &outputConnectionSpec) override |
| Disconnect to the output connection. | |
| virtual IPoolSvc * | getPoolSvc () override |
| virtual Token * | registerForWrite (Placement *placement, const void *obj, const RootType &classDesc) override |
| virtual void | setObjPtr (void *&obj, const Token *token) override |
| virtual bool | useDetailChronoStat () const override |
| 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. | |
| virtual StatusCode | createAddress (long svcType, const CLID &clid, const std::string &refAddress, IOpaqueAddress *&refpAddress) override |
| Create address from string form. | |
| virtual StatusCode | convertAddress (const IOpaqueAddress *pAddress, std::string &refAddress) override |
| Convert address to string form. | |
| virtual StatusCode | decodeOutputSpec (std::string &connectionSpec, int &outputTech) const override |
| Extract/deduce the DB technology from the connection string/file specification. | |
| virtual StatusCode | registerCleanUp (IAthenaPoolCleanUp *cnv) override |
| Implement registerCleanUp to register a IAthenaPoolCleanUp to be called during cleanUp. | |
| virtual StatusCode | cleanUp (const std::string &connection) override |
| Implement cleanUp to call all registered IAthenaPoolCleanUp cleanUp() function. | |
| virtual StatusCode | setInputAttributes (const std::string &fileName) override |
| Set the input file attributes, if any are requested from jobOpts. | |
| virtual void | handle (const Incident &incident) override |
| Implementation of IIncidentListener: Handle for EndEvent incidence. | |
| void | flushDataHeaderForms (const std::string &streamName="*") |
| Tell DataHeaderCnv to write out all DataHeaderForms for a given streamName (default is all) | |
| AthenaPoolCnvSvc (const std::string &name, ISvcLocator *pSvcLocator) | |
| Standard Service Constructor. | |
| virtual | ~AthenaPoolCnvSvc ()=default |
| Destructor. | |
Protected Member Functions | |
| unsigned | outputContextId (const std::string &outputConnection) |
Protected Attributes | |
| PMonUtils::BasicStopWatchResultMap_t | m_chronoMap {} |
| Map that holds chrono information. | |
| Gaudi::Property< bool > | m_persSvcPerOutput {this,"PersSvcPerOutput",true} |
| PersSvcPerOutput, boolean property to use multiple persistency services, one per output stream. | |
| Gaudi::Property< std::string > | m_persSvcPerInputType {this,"PersSvcPerInputType",""} |
| PersSvcPerInputType, string property, tree name to use multiple persistency services, one per input type. | |
| std::mutex | m_mutex |
| Gaudi::Property< int > | m_numberEventsPerWrite {this,"NumberEventsPerWrite",-1} |
| To use MetadataSvc to merge data placed in a certain container When using TMemFile call Write on number of Events, respecting CollectionTree auto_flush. | |
| Gaudi::Property< bool > | m_oneDataHeaderForm { this, "OneDataHeaderForm", false } |
| If true, use only one DataHeaderForm per Stream. | |
| Gaudi::Property< int > | m_DHFormCacheSize { this, "maxDHFormCacheSize", 100 } |
| Property for DataHeaderCnv input DHForm cache size. | |
| Gaudi::Property< bool > | m_DHFilterAliases { this, "doFilterDHAliases", true } |
| Flag to control SG alias filtering when writing out DataHeader (see DataHeaderCnv_p6) | |
Private Member Functions | |
| 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. | |
| 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. | |
Private Attributes | |
| std::string | m_lastInputFileName |
| decoded storage tech requested in "StorageTechnology" property | |
| ServiceHandle< IPoolSvc > | m_poolSvc {this,"PoolSvc","PoolSvc"} |
| ServiceHandle< IClassIDSvc > | m_clidSvc {this,"ClassIDSvc","ClassIDSvc"} |
| Gaudi::Property< bool > | m_useDetailChronoStat {this,"UseDetailChronoStat",false} |
| UseDetailChronoStat, enable detailed output for time and size statistics for AthenaPOOL: default = false. | |
| Gaudi::Property< std::map< std::string, std::string > > | m_storageTechProp {this, "StorageTechnology", {{"*","ROOTTREEINDEX"}}} |
| Default Storage Tech for containers (ROOTTREE, ROOTTREEINDEX, ROOTRNTUPLE) | |
| std::map< std::string, int > | m_storageTechMap |
| Gaudi::Property< std::string > | m_containerPrefixProp {this,"PoolContainerPrefix","Default"} |
| POOL Container name prefix - will be part of or whole TTree/RNTuple name 'Default' takes the prefix from APRDefaults according to StorageTech. | |
| Gaudi::Property< std::string > | m_containerNameHintProp {this,"TopLevelContainerName",""} |
| TopLevelContainerName, naming hint policy for top level POOL container: default = "<type>". | |
| Gaudi::Property< std::string > | m_branchNameHintProp {this,"SubLevelBranchName", "<type>/<key>"} |
| SubLevelBranchName, naming hint policy for POOL branching: ("" = no branching) | |
| Gaudi::Property< std::vector< std::string > > | m_poolAttr {this,"PoolAttributes",{},"Pool Attributes","OrderedSet<std::string>"} |
| Output PoolAttributes, vector with names and values of technology specific attributes for POOL. | |
| std::vector< std::vector< std::string > > | m_domainAttr |
| std::vector< std::vector< std::string > > | m_databaseAttr |
| std::vector< std::vector< std::string > > | m_containerAttr |
| std::vector< unsigned int > | m_contextAttr |
| std::map< std::string, int > | m_fileCommitCounter |
| std::map< std::string, int > | m_fileFlushSetting |
| Gaudi::Property< std::vector< std::string > > | m_inputPoolAttr {this,"InputPoolAttributes",{}} |
| Input PoolAttributes, vector with names and values of technology specific attributes for POOL. | |
| std::vector< std::vector< std::string > > | m_inputAttr |
| Gaudi::Property< std::vector< std::string > > | m_inputPoolAttrPerEvent {this,"PrintInputAttrPerEvt",{}} |
| Print input PoolAttributes per event, vector with names of technology specific attributes for POOL to be printed each event. | |
| std::vector< std::vector< std::string > > | m_inputAttrPerEvent |
| Gaudi::Property< std::vector< std::string > > | m_maxFileSizes {this,"MaxFileSizes",{}} |
| MaxFileSizes, vector with maximum file sizes for Athena POOL output files. | |
| long long | m_domainMaxFileSize =std::numeric_limits<long long>::max() |
| std::map< std::string, long long > | m_databaseMaxFileSize |
| std::string | m_defContainerType {} |
| Default container type (from PoolSvc) | |
Friends | |
| class | SvcFactory< AthenaPoolCnvSvc > |
This class provides the interface between Athena and PoolSvc.
Definition at line 40 of file AthenaPoolCnvSvc.h.
| AthenaPoolCnvSvc::AthenaPoolCnvSvc | ( | const std::string & | name, |
| ISvcLocator * | pSvcLocator ) |
|
virtualdefault |
Destructor.
|
overridevirtual |
Implement cleanUp to call all registered IAthenaPoolCleanUp cleanUp() function.
Definition at line 546 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implementation of IConversionSvc: Commit pending output.
| doCommit | [IN] boolean to force full commit |
Definition at line 343 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implementation of IConversionSvc: Connect to the output connection specification with open mode.
| outputConnectionSpec | [IN] the name of the output connection specification as string. |
Definition at line 271 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implementation of IConversionSvc: Connect to the output connection specification with open mode.
| outputConnectionSpec | [IN] the name of the output connection specification as string. |
| openMode | [IN] the open mode of the file as string. |
Definition at line 266 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Convert address to string form.
| pAddress | [IN] address to be converted. |
| refAddress | [OUT] converted string form. |
Definition at line 494 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Create address from string form.
| svcType | [IN] service type of the address. |
| clid | [IN] class id for the address. |
| refAddress | [IN] string form to be converted. |
| refpAddress | [OUT] converted address. |
Definition at line 482 of file AthenaPoolCnvSvc.cxx.
|
override |
Create a Generic address using explicit arguments to identify a single object.
| svcType | [IN] service type of the address. |
| clid | [IN] class id for the address. |
| par | [IN] string containing the database name. |
| ip | [IN] object identifier. |
| refpAddress | [OUT] converted address. |
Definition at line 456 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implementation of IConversionSvc: Create the transient representation of an object from persistent state.
| pAddress | [IN] pointer to IOpaqueAddress of the representation. |
| refpObject | [OUT] pointer to DataObject to be created. |
Definition at line 170 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implementation of IConversionSvc: Convert the transient object to the requested representation.
| pObject | [IN] pointer to DataObject. |
| refpAddress | [OUT] pointer to IOpaqueAddress of the representation to be created. |
Definition at line 204 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Extract/deduce the DB technology from the connection string/file specification.
Definition at line 506 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Disconnect to the output connection.
Definition at line 409 of file AthenaPoolCnvSvc.cxx.
|
private |
Extract POOL ItechnologySpecificAttributes for Domain, Database and Container from property.
Definition at line 601 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implementation of IConversionSvc: Resolve the references of the converted object.
| pAddress | [IN] pointer to IOpaqueAddress of the representation to be resolved. |
| pObject | [IN] pointer to DataObject to be created. |
Definition at line 235 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Required of all Gaudi Services.
Definition at line 136 of file AthenaPoolCnvSvc.cxx.
| void AthenaPoolCnvSvc::flushDataHeaderForms | ( | const std::string & | streamName = "*" | ) |
Tell DataHeaderCnv to write out all DataHeaderForms for a given streamName (default is all)
Definition at line 122 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Definition at line 423 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implementation of IIncidentListener: Handle for EndEvent incidence.
Definition at line 589 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Required of all Gaudi Services.
Definition at line 35 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Definition at line 165 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Definition at line 116 of file AthenaPoolCnvSvc.cxx.
|
protected |
Definition at line 417 of file AthenaPoolCnvSvc.cxx.
|
private |
Set/get technology dependent POOL attributes.
Definition at line 654 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Implement registerCleanUp to register a IAthenaPoolCleanUp to be called during cleanUp.
Definition at line 541 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
| placement | [IN] pointer to the placement hint |
| obj | [IN] pointer to the Data Object to be written to Pool |
| classDesc | [IN] pointer to the Seal class description for the Data Object. |
Definition at line 427 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Set the input file attributes, if any are requested from jobOpts.
| fileName | [IN] name of the input file |
Definition at line 567 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
| obj | [OUT] pointer to the Data Object. |
| token | [IN] string token of the Data Object for which a Pool Ref is filled. |
Definition at line 442 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Definition at line 129 of file AthenaPoolCnvSvc.cxx.
|
overridevirtual |
Definition at line 452 of file AthenaPoolCnvSvc.cxx.
|
friend |
Definition at line 1 of file AthenaPoolCnvSvc.h.
|
private |
SubLevelBranchName, naming hint policy for POOL branching: ("" = no branching)
Definition at line 197 of file AthenaPoolCnvSvc.h.
|
protected |
|
private |
Definition at line 177 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 203 of file AthenaPoolCnvSvc.h.
|
private |
TopLevelContainerName, naming hint policy for top level POOL container: default = "<type>".
Definition at line 195 of file AthenaPoolCnvSvc.h.
|
private |
POOL Container name prefix - will be part of or whole TTree/RNTuple name 'Default' takes the prefix from APRDefaults according to StorageTech.
Definition at line 193 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 204 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 202 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 218 of file AthenaPoolCnvSvc.h.
|
private |
|
protected |
Flag to control SG alias filtering when writing out DataHeader (see DataHeaderCnv_p6)
Definition at line 243 of file AthenaPoolCnvSvc.h.
|
protected |
Property for DataHeaderCnv input DHForm cache size.
Definition at line 241 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 201 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 217 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 205 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 206 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 209 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 213 of file AthenaPoolCnvSvc.h.
|
private |
Input PoolAttributes, vector with names and values of technology specific attributes for POOL.
Definition at line 208 of file AthenaPoolCnvSvc.h.
|
private |
Print input PoolAttributes per event, vector with names of technology specific attributes for POOL to be printed each event.
Definition at line 212 of file AthenaPoolCnvSvc.h.
|
private |
decoded storage tech requested in "StorageTechnology" property
Definition at line 175 of file AthenaPoolCnvSvc.h.
|
private |
MaxFileSizes, vector with maximum file sizes for Athena POOL output files.
Definition at line 216 of file AthenaPoolCnvSvc.h.
|
protected |
Definition at line 232 of file AthenaPoolCnvSvc.h.
|
protected |
To use MetadataSvc to merge data placed in a certain container When using TMemFile call Write on number of Events, respecting CollectionTree auto_flush.
Definition at line 236 of file AthenaPoolCnvSvc.h.
|
protected |
If true, use only one DataHeaderForm per Stream.
Definition at line 239 of file AthenaPoolCnvSvc.h.
|
protected |
PersSvcPerInputType, string property, tree name to use multiple persistency services, one per input type.
default = "", no tree name results in a single persistency service.
Definition at line 231 of file AthenaPoolCnvSvc.h.
|
protected |
PersSvcPerOutput, boolean property to use multiple persistency services, one per output stream.
default = true.
Definition at line 226 of file AthenaPoolCnvSvc.h.
|
private |
Output PoolAttributes, vector with names and values of technology specific attributes for POOL.
Definition at line 200 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 176 of file AthenaPoolCnvSvc.h.
|
private |
Definition at line 190 of file AthenaPoolCnvSvc.h.
|
private |
Default Storage Tech for containers (ROOTTREE, ROOTTREEINDEX, ROOTRNTUPLE)
Definition at line 189 of file AthenaPoolCnvSvc.h.
|
private |
UseDetailChronoStat, enable detailed output for time and size statistics for AthenaPOOL: default = false.
Definition at line 186 of file AthenaPoolCnvSvc.h.