ATLAS Offline Software
|
Hold mappings of ranges to condition objects. More...
#include "AthenaKernel/ClassID_traits.h"
#include "AthenaKernel/CLASS_DEF.h"
#include "AthenaKernel/BaseInfo.h"
#include "AthenaKernel/RCUUpdater.h"
#include "AthenaKernel/IConditionsCleanerSvc.h"
#include "AthenaKernel/CondObjDeleter.h"
#include "CxxUtils/ConcurrentRangeMap.h"
#include "CxxUtils/ConcurrentPtrSet.h"
#include "CxxUtils/SimpleUpdater.h"
#include "CxxUtils/checker_macros.h"
#include "GaudiKernel/EventIDBase.h"
#include "GaudiKernel/EventIDRange.h"
#include "GaudiKernel/DataObjID.h"
#include "GaudiKernel/StatusCode.h"
#include "GaudiKernel/ServiceHandle.h"
#include "boost/preprocessor/facilities/overload.hpp"
#include <iostream>
#include <set>
#include <vector>
#include <typeinfo>
#include <mutex>
#include <type_traits>
#include "AthenaKernel/CondCont.icc"
#include "AthenaKernel/CondContMaker.h"
Go to the source code of this file.
Classes | |
class | CondContBase |
Base class for all conditions containers. More... | |
class | CondContBase::Category |
Status code category for ContCont. More... | |
struct | CondContBase::RangeKey |
Range object to store in ConcurrentRangeMap . More... | |
struct | CondContBase::Compare |
Comparison object needed by ConcurrentRangeMap. More... | |
class | CondContSingleBase |
Base class for conditions containers that are either Run+LBN or timestamp. More... | |
class | CondCont< T > |
Hold mapping of ranges to condition objects. More... | |
class | CondContBaseInfo< T > |
Traits class to find the base for CondCont . More... | |
struct | SG::Bases< CondCont< T > > |
class | CondCont< T > |
Hold mapping of ranges to condition objects. More... | |
class | CondContMixedBase |
Base class for conditions containers for which keys are ranges in both Run+LBN and timestamp. More... | |
class | CondContMixed< T > |
Conditions container for which keys are ranges in both Run+LBN and timestamp. More... | |
class | CondContMixedBaseInfo< T > |
Traits class to find the base for CondContMixed . More... | |
struct | SG::Bases< CondContMixed< T > > |
class | CondContMixed< T > |
Conditions container for which keys are ranges in both Run+LBN and timestamp. More... | |
Namespaces | |
SG | |
Forward declaration. | |
Athena | |
Some weak symbol referencing magic... | |
Macros | |
#define | CONDCONT_BASE(D, B) |
Declare that conditions object D derives from B . More... | |
#define | CONDCONT_MIXED_BASE(D, B) |
Declare that conditions object D derives from B . More... | |
#define | CONCATUNF_(x, y) x##y |
#define | CONCATUNF(x, y) CONCATUNF_(x,y) |
#define | UNIQUEVARNAME CONCATUNF(CONCATUNF(REGCCM_,__COUNTER__),__LINE__) |
#define | CONDCONT_DEF_2(T, CLID_) |
Declare a conditions container along with its CLID. More... | |
#define | CONDCONT_DEF_3(T, CLID_, BASE) |
#define | CONDCONT_DEF(...) BOOST_PP_OVERLOAD(CONDCONT_DEF_, __VA_ARGS__)(__VA_ARGS__) |
#define | CONDCONT_MIXED_DEF_2(T, CLID_) |
Declare a conditions container along with its CLID. More... | |
#define | CONDCONT_MIXED_DEF_3(T, CLID_, BASE) |
#define | CONDCONT_MIXED_DEF(...) BOOST_PP_OVERLOAD(CONDCONT_MIXED_DEF_, __VA_ARGS__)(__VA_ARGS__) |
Enumerations | |
enum | CondContStatusCode : StatusCode::code_t { CondContStatusCode::FAILURE = 0, CondContStatusCode::SUCCESS = 1, CondContStatusCode::RECOVERABLE = 2, CondContStatusCode::DUPLICATE = 10, CondContStatusCode::OVERLAP = 11, CondContStatusCode::EXTENDED = 12 } |
Define extended status codes used by CondCont. More... | |
Hold mappings of ranges to condition objects.
T
are managed by CondCont<T>
, which are recorded in the conditions store. CondCont<T>
is a map of IOV ranges to payload objects of type T
.A conditions container must be declared as such and given a CLID using the macro CONDCONT_DEF:
If one payload class derives from another, it is possible declare conditions containers so that they have the same inheritance by adding the payload base class as a thir argument to CONDCONT_DEF
. For example, if MyType
derived from MyBase
then you can use
A conditions container declared in this way should have keys that are either ranges in run+lbn or timestamp; they cannot be mixed. However, in the case where one has a conditions algorithm that takes as input both a run+lbn and a timestamp condition, the result will be IOVs that have both run+lbn and timestamp ranges. Such conditions may be stored in a mixed conditions container, declared as:
CondCont<MyType>
is now declared as a mixed container. Mixed containers may also participate in inheritance, but the base class declared for a mixed container must also have been declared as mixed.
Implementation notes: All conditions containers derive from CondContBase
. This defines virtual functions that are used by the IOV services. CondContSingleBase
derives from this and collects non-templated implementations used by non-mixed containers; most virtual functions can be declared final
here. Finally, CondCont<T>
derives from CondContSingleBase
and implements the type-specific part.
We reduce the amount of templated code that must be instantiated by storing the payloads as void* in the underlying ConcurrentRangeMap
. All this needs to do with the payloads is to be able to delete them; we handle this by giving ConcurrentRangeMap
a function to call to delete a payload.
For the case of mixed containers, rather than having the ConcurrentRangeMap
store the payload directly, it instead holds another ConcurrentRangeMap
which in turn hold the payload. The top map is indexed by run+lbn and the secondary ones by timestamp.
For mixed containers, we have CondContMixedBase
deriving from CondContBase
and CondContMixed<T>
deriving from that. The CONDCONT_MIXED_DEF
macro then specializes CondCont<T>
so that it derives from CondContMixed<T>
Definition in file CondCont.h.
#define CONCATUNF | ( | x, | |
y | |||
) | CONCATUNF_(x,y) |
Definition at line 1397 of file CondCont.h.
#define CONDCONT_BASE | ( | D, | |
B | |||
) |
Declare that conditions object D
derives from B
.
This allows using ReadCondHandle
to retrieve a conditions object of type D
as B
.
Definition at line 847 of file CondCont.h.
#define CONDCONT_DEF | ( | ... | ) | BOOST_PP_OVERLOAD(CONDCONT_DEF_, __VA_ARGS__)(__VA_ARGS__) |
Definition at line 1414 of file CondCont.h.
#define CONDCONT_DEF_2 | ( | T, | |
CLID_ | |||
) |
Declare a conditions container along with its CLID.
Definition at line 1408 of file CondCont.h.
#define CONDCONT_DEF_3 | ( | T, | |
CLID_, | |||
BASE | |||
) |
Definition at line 1411 of file CondCont.h.
#define CONDCONT_MIXED_BASE | ( | D, | |
B | |||
) |
Declare that conditions object D
derives from B
.
This allows using ReadCondHandle
to retrieve a conditions object of type D
as B
.
Definition at line 1232 of file CondCont.h.
#define CONDCONT_MIXED_DEF | ( | ... | ) | BOOST_PP_OVERLOAD(CONDCONT_MIXED_DEF_, __VA_ARGS__)(__VA_ARGS__) |
Definition at line 1447 of file CondCont.h.
#define CONDCONT_MIXED_DEF_2 | ( | T, | |
CLID_ | |||
) |
Declare a conditions container along with its CLID.
Definition at line 1427 of file CondCont.h.
#define CONDCONT_MIXED_DEF_3 | ( | T, | |
CLID_, | |||
BASE | |||
) |
Definition at line 1444 of file CondCont.h.
Definition at line 1398 of file CondCont.h.
|
strong |
Define extended status codes used by CondCont.
We add DUPLICATE, OVERLAP, and EXTENDED.
Enumerator | |
---|---|
FAILURE | |
SUCCESS | |
RECOVERABLE | |
DUPLICATE | |
OVERLAP | |
EXTENDED |
Definition at line 107 of file CondCont.h.