Class ChunkReadOperation

Nested Relationships

Nested Types

Inheritance Relationships

Base Type

Class Documentation

class gkfs::data::ChunkReadOperation : public gkfs::data::ChunkOperation<ChunkReadOperation>

Chunk operation class for read operations with one object per read RPC request. May involve multiple I/O task depending on the number of chunks involved.

Public Functions

ChunkReadOperation(const std::string &path, size_t n)
~ChunkReadOperation() = default
void read_nonblock(size_t idx, uint64_t chunk_id, char *bulk_buf_ptr, size_t size, off64_t offset)

Read request called by RPC handler function and launches a non-blocking tasklet.

Parameters
  • idx – Number of non-blocking write for write RPC request

  • chunk_id – The affected chunk id

  • bulk_buf_ptr – The buffer for reading chunk

  • size – Size to read from chunk

  • offset – Offset for individual chunk

Throws

ChunkReadOpException

std::pair<int, size_t> wait_for_tasks_and_push_back(const bulk_args &args)

Waits for all local I/O operations to finish and push buffers back to the daemon.

Parameters

args – Bulk_args for push transfer

Returns

Pair for error code for success (0) or failure and read size

Private Functions

void clear_task_args()

Resets the task_arg_ struct.

Private Members

std::vector<struct chunk_read_args> task_args_

tasklet input structs

Private Static Functions

static void read_file_abt(void *_arg)

Exclusively used by the Argobots tasklet.

Parameters

_arg – Pointer to input struct of type <chunk_read_args>. Error code<int> is placed into eventual to signal its failure or success.

Friends

friend class ChunkOperation< ChunkReadOperation >
struct bulk_args

Struct to push read data to the client.

Public Members

margo_instance_id mid

Margo instance ID of server.

hg_addr_t origin_addr

abstract address of client

hg_bulk_t origin_bulk_handle

bulk handle from client

std::vector<size_t> *origin_offsets

offsets in origin buffer

hg_bulk_t local_bulk_handle

local bulk handle for PUSH

std::vector<size_t> *local_offsets

offsets in local buffer

std::vector<uint64_t> *chunk_ids

all chunk ids in this read

struct chunk_read_args

Struct for an chunk read operation.

Public Members

const std::string *path

Path to affected chunk directory.

char *buf

Buffer for chunk.

gkfs::rpc::chnk_id_t chnk_id

chunk id that is affected

size_t size

size to read from chunk

off64_t off

offset for individual chunk

ABT_eventual eventual

Attached eventual.