|
ATLAS Offline Software
|
Go to the documentation of this file.
7 #ifndef SGCOMPS_ADDRESSREMAPPINGSVC_H
8 #define SGCOMPS_ADDRESSREMAPPINGSVC_H 1
15 #include "GaudiKernel/ClassID.h"
16 #include "GaudiKernel/ServiceHandle.h"
17 #include "Gaudi/Property.h"
21 #include "GaudiKernel/IAlgResourcePool.h"
40 :
public extends<AthService, Athena::IInputRename, IAddressProvider>
69 const EventContext& ctx)
override;
77 virtual const IInputRename::InputRenameRCU_t*
inputRenameMap()
const override;
83 "the IProxyDict we want to apply the remapping to (by default the event store)"};
86 "Algorithm resource pool service."};
89 StringArrayProperty
m_overwriteMaps{
this,
"TypeKeyOverwriteMaps",{},
"",
"OrderedSet<std::string>"};
102 "List of renamings to apply to input objects. This is distinct from the "
103 "mappings given by TypeKeyOverwriteMaps in that objects listed under "
104 "TypeKeyOverwriteMaps are accessible by both the old and new names; "
105 "while for TypeKeyRenameMaps, only the new names are visible (so the old names "
106 "may be rewritten). Overwriting may also change the visible type of an object, "
107 "while renaming may not. Format of list elements is OLDNAME#TYPE->NEWNAME.",
"OrderedSet<std::string>"};
117 "If true, will delay the remapping setup until the first load, and will check against the given file"};
132 const EventContext& ctx)
const;
155 #endif // !SGCOMPS_ADDRESSREMAPPINGSVC_H
Wrapper object controlled by RCU synchonization.
Athena::IInputRename::InputRenameMap_t InputRenameMap_t
Map of sgkey->sgkey for input renames.
bool isDeleted(const SG::TransientAddress &tad) const
virtual ~AddressRemappingSvc()
Destructor.
Gaudi::Property< bool > m_skipBadRemappings
read-copy-update (RCU) style synchronization for Athena.
void addInputRenames(const InputRenameMap_t &toadd) const
Merge in additional input rename mappings.
virtual StatusCode initialize ATLAS_NOT_THREAD_SAFE() override
Required of all Gaudi services:
StatusCode initInputRenames ATLAS_NOT_THREAD_SAFE()
Set up input rename mappings during initialization.
std::unique_ptr< InputRenameRCU_t > m_inputRenames
std::vector< SG::TransientAddress > m_oldTads
CxxUtils::CachedValue< std::vector< SG::TransientAddress > > m_oldTadsCleaned
std::atomic< bool > m_haveDeletes
AddressRemappingSvc(const std::string &name, ISvcLocator *pSvcLocator)
Standard Service Constructor.
CLID getClid(std::string type) const
virtual StatusCode loadAddresses(StoreID::type storeID, IAddressProvider::tadList &tads) override
Implementation of the loadAddresses function without any functionality.
ServiceHandle< IClassIDSvc > m_clidSvc
StringArrayProperty m_overwriteMaps
TypeKeyOverwriteMaps, map for type::key overwrites.
CxxUtils::CachedValue< std::vector< SG::TransientAddress > > m_newTadsCleaned
StatusCode renameTads(IAddressProvider::tadList &tads) const
Scan TAD list and carry out any requested renamings.
ServiceHandle< IAlgResourcePool > m_algResourcePool
::StatusCode StatusCode
StatusCode definition for legacy code.
Cached value with atomic update.
uint32_t CLID
The Class ID type.
ServiceHandle< Athena::IRCUSvc > m_RCUSvc
std::unordered_multimap< std::string, CLID > m_deletes
Cached value with atomic update.
StatusCode preLoadAddressesConst(StoreID::type storeID, IAddressProvider::tadList &tads) const
ServiceHandle< IProxyDict > m_proxyDict
virtual StatusCode preLoadAddresses(StoreID::type storeID, IAddressProvider::tadList &tads) override
Get all addresses from provider.
StatusCode updateAddressConst(StoreID::type, SG::TransientAddress *pTad, const EventContext &ctx) const
Gaudi::Property< std::vector< std::string > > m_typeKeyRenameMaps
Property: list of requested input renames.
virtual const IInputRename::InputRenameRCU_t * inputRenameMap() const override
Retrieve a pointer to the input rename map.
std::list< SG::TransientAddress * > tadList
virtual StatusCode updateAddress(StoreID::type, SG::TransientAddress *pTad, const EventContext &ctx) override
Update a transient address.
StatusCode loadAddressesConst(IAddressProvider::tadList &tads) const
Athena::IInputRename::InputRenameRCU_t InputRenameRCU_t
Define macros for attributes used to control the static checker.
std::mutex m_deletesMutex
virtual StatusCode finalize() override
Required of all Gaudi services:
std::vector< SG::TransientAddress > m_newTads