32#include <unordered_map>
34#ifndef DAOS_UUID_STR_SIZE
35#define DAOS_UUID_STR_SIZE 37
40namespace Experimental {
180 auto seed = std::hash<uint64_t>{}(
x.oid.hi);
181 seed ^= std::hash<uint64_t>{}(
x.oid.lo) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
182 seed ^= std::hash<DistributionKey_t>{}(
x.dkey) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
202 std::unordered_map<AttributeKey_t, unsigned>
fIndices{};
207 unsigned attrIndex = it->second;
219 unsigned attrIndex = it->second;
225 std::make_move_iterator(std::begin(iovs)),
226 std::make_move_iterator(std::end(iovs)));
253 RDaosContainer(std::shared_ptr<RDaosPool> pool, std::string_view containerId,
bool create =
false);
RooAbsTestStatistic * create(const char *name, const char *title, RooAbsReal &real, RooAbsData &adata, const RooArgSet &projDeps, RooAbsTestStatistic::Configuration const &cfg) override
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h length
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t attr
A RDaosContainer provides read/write access to objects in a given container.
void SetDefaultObjectClass(const ObjClassId_t cid)
std::shared_ptr< RDaosPool > fPool
ObjClassId_t GetDefaultObjectClass() const
int ReadV(MultiObjectRWOperation_t &map, ObjClassId_t cid)
Perform a vector read operation on multiple objects.
int WriteSingleAkey(const void *buffer, std::size_t length, daos_obj_id_t oid, DistributionKey_t dkey, AttributeKey_t akey)
std::unordered_map< ROidDkeyPair, RWOperation, ROidDkeyPair::Hash > MultiObjectRWOperation_t
int ReadV(MultiObjectRWOperation_t &map)
int WriteV(MultiObjectRWOperation_t &map, ObjClassId_t cid)
Perform a vector write operation on multiple objects.
daos_handle_t fContainerHandle
int WriteV(MultiObjectRWOperation_t &map)
int ReadSingleAkey(void *buffer, std::size_t length, daos_obj_id_t oid, DistributionKey_t dkey, AttributeKey_t akey, ObjClassId_t cid)
Read data from a single object attribute key to the given buffer.
std::string fContainerLabel
RDaosObject::ObjClassId ObjClassId_t
RDaosObject::DistributionKey_t DistributionKey_t
std::string GetContainerUuid()
int ReadSingleAkey(void *buffer, std::size_t length, daos_obj_id_t oid, DistributionKey_t dkey, AttributeKey_t akey)
RDaosObject::AttributeKey_t AttributeKey_t
ObjClassId_t fDefaultObjectClass
int VectorReadWrite(MultiObjectRWOperation_t &map, ObjClassId_t cid, int(RDaosObject::*fn)(RDaosObject::FetchUpdateArgs &))
Perform a vector read/write operation on different objects.
int WriteSingleAkey(const void *buffer, std::size_t length, daos_obj_id_t oid, DistributionKey_t dkey, AttributeKey_t akey, ObjClassId_t cid)
Write the given buffer to a single object attribute key.
Provides low-level access to DAOS objects in a container.
std::uint64_t DistributionKey_t
int Update(FetchUpdateArgs &args)
daos_handle_t fObjectHandle
std::uint64_t AttributeKey_t
int Fetch(FetchUpdateArgs &args)
A RDaosPool provides access to containers in a specific DAOS pool.
RDaosPool & operator=(const RDaosPool &)=delete
std::string GetPoolUuid()
daos_handle_t fPoolHandle
std::unique_ptr< RDaosEventQueue > fEventQueue
RDaosPool(const RDaosPool &)=delete
This file is a reduced version of daos_xxx.h headers that provides (simplified) declarations for use ...
int daos_oclass_name2id(const char *name)
uint16_t daos_oclass_id_t
This file contains a specialised ROOT message handler to test for diagnostic in unit tests.
auto operator()(const ROidDkeyPair &x) const
A pair of <object ID, distribution key> that can be used to issue a fetch/update request for multiple...
bool operator==(const ROidDkeyPair &other) const
Describes a read/write operation on multiple attribute keys under the same object ID and distribution...
DistributionKey_t fDistributionKey
void Insert(AttributeKey_t attr, std::vector< d_iov_t > &iovs)
void Insert(AttributeKey_t attr, const d_iov_t &iov)
RWOperation(ROidDkeyPair &k)
RWOperation(daos_obj_id_t o, DistributionKey_t d, std::vector< RDaosObject::RAkeyRequest > &&rs)
std::vector< RDaosObject::RAkeyRequest > fDataRequests
std::unordered_map< AttributeKey_t, unsigned > fIndices
static int FinalizeEvent(daos_event_t *ev_ptr)
Release event data from queue.
static int WaitOnParentBarrier(daos_event_t *ev_ptr)
Sets event barrier for a given parent event and waits for the completion of all children launched bef...
int InitializeEvent(daos_event_t *ev_ptr, daos_event_t *parent_ptr=nullptr) const
Reserve event in queue, optionally tied to a parent event.
Contains required information for a single fetch/update operation.
FetchUpdateArgs & operator=(const FetchUpdateArgs &)=delete
std::vector< daos_iod_t > fIods
FetchUpdateArgs()=default
FetchUpdateArgs(const FetchUpdateArgs &)=delete
DistributionKey_t fDkey
A daos_key_t is a type alias of d_iov_t.
daos_key_t fDistributionKey
The distribution key, as used by the daos_obj_{fetch,update} functions.
std::span< RAkeyRequest > fRequests
fRequests is a sequential container assumed to remain valid throughout the fetch/update operation,...
std::vector< d_sg_list_t > fSgls
std::optional< daos_event_t > fEvent
daos_event_t * GetEventPointer()
Wrap around a daos_oclass_id_t.
std::string ToString() const
ObjClassId(const std::string &name)
static constexpr std::size_t kOCNameMaxLength
This limit is currently not defined in any header and any call to daos_oclass_id2name() within DAOS u...
ObjClassId(daos_oclass_id_t cid)
Contains an attribute key and the associated IOVs for a single scatter-gather I/O request.
RAkeyRequest(const AttributeKey_t a, std::vector< d_iov_t > &&iovs)
RAkeyRequest(const AttributeKey_t a, const std::vector< d_iov_t > &iovs)
std::vector< d_iov_t > fIovs
Generic handle for various DAOS components like container, object, etc.