24 static struct RDaosRAII {
34 } Svc(serviceReplicas);
52 char name[kOCNameMaxLength + 1] = {};
54 return std::string{
name};
59 : fDkey(fua.fDkey), fAkey(fua.fAkey),
60 fIods{fua.fIods[0]}, fSgls{fua.fSgls[0]}, fIovs(std::move(fua.fIovs)), fEv(fua.fEv)
68 : fDkey(
d), fAkey(
a), fIovs(
v), fEv(p)
120 for (std::size_t i = 0; i <
fSize; ++i)
125 for (std::size_t i = 0; i <
fSize; ++i)
147 std::string_view containerUuid,
bool create)
170 std::vector<d_iov_t> iovs(1);
180 std::vector<d_iov_t> iovs(1);
181 d_iov_set(&iovs[0],
const_cast<void *
>(buffer), length);
void d_rank_list_free(d_rank_list_t *rank_list)
#define R__FAIL(msg)
Short-hand to return an RResult<T> in an error state; the RError is implicitly converted into RResult...
size_t size(const MatrixT &matrix)
retrieve the size of a square matrix
A RDaosContainer provides read/write access to objects in a given container.
std::shared_ptr< RDaosPool > fPool
daos_handle_t fContainerHandle
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.
RDaosObject::DistributionKey_t DistributionKey_t
RDaosObject::AttributeKey_t AttributeKey_t
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.
RDaosContainer(std::shared_ptr< RDaosPool > pool, std::string_view containerUuid, bool create=false)
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)
daos_handle_t fPoolHandle
RDaosPool(const RDaosPool &)=delete
Base class for all ROOT issued exceptions.
int daos_oclass_id2name(daos_oclass_id_t oc_id, char *name)
const char * d_errstr(int rc)
int daos_pool_disconnect(daos_handle_t poh, daos_event_t *ev)
int daos_obj_fetch(daos_handle_t oh, daos_handle_t th, uint64_t flags, daos_key_t *dkey, unsigned int nr, daos_iod_t *iods, d_sg_list_t *sgls, daos_iom_t *ioms, daos_event_t *ev)
static void d_iov_set(d_iov_t *iov, void *buf, size_t size)
int daos_obj_open(daos_handle_t coh, daos_obj_id_t oid, unsigned int mode, daos_handle_t *oh, daos_event_t *ev)
int daos_cont_create(daos_handle_t poh, const uuid_t uuid, daos_prop_t *cont_prop, daos_event_t *ev)
int daos_event_fini(daos_event_t *ev)
int daos_obj_update(daos_handle_t oh, daos_handle_t th, uint64_t flags, daos_key_t *dkey, unsigned int nr, daos_iod_t *iods, d_sg_list_t *sgls, daos_event_t *ev)
int daos_cont_close(daos_handle_t coh, daos_event_t *ev)
int daos_event_init(daos_event_t *ev, daos_handle_t eqh, daos_event_t *parent)
static int daos_obj_generate_id(daos_obj_id_t *oid, daos_ofeat_t ofeats, daos_oclass_id_t cid, uint32_t args)
int daos_eq_create(daos_handle_t *eqh)
int daos_cont_open(daos_handle_t poh, const uuid_t uuid, unsigned int flags, daos_handle_t *coh, daos_cont_info_t *info, daos_event_t *ev)
int daos_pool_connect(const uuid_t uuid, const char *grp, const d_rank_list_t *svc, unsigned int flags, daos_handle_t *poh, daos_pool_info_t *info, daos_event_t *ev)
d_rank_list_t * daos_rank_list_parse(const char *str, const char *sep)
@ DAOS_REC_ANY
Any record size, it is used by fetch.
int daos_obj_close(daos_handle_t oh, daos_event_t *ev)
int daos_eq_destroy(daos_handle_t eqh, int flags)
int daos_eq_poll(daos_handle_t eqh, int wait_running, int64_t timeout, unsigned int nevents, daos_event_t **events)
#define DAOS_EQ_WAIT
Wait for completion event forever.
std::unique_ptr< daos_event_t[]> fEvs
int Poll()
Wait for all events in this event queue to complete.
DaosEventQueue(std::size_t size)
Contains required information for a single fetch/update operation.
FetchUpdateArgs()=default
std::vector< d_iov_t > fIovs
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.
Wrap around a daos_oclass_id_t.
std::string ToString() const