NVIDIA DOCA SDK Data Center on a Chip Framework Documentation
storage::control Namespace Reference

Data Structures

class  channel
 
class  comch_channel
 
struct  message_id
 
struct  correlation_id
 
struct  message_header
 
struct  message
 
struct  error_response_payload
 
struct  storage_details_payload
 
struct  init_storage_payload
 
struct  rdma_connection_details_payload
 

Enumerations

enum class  rdma_connection_role { io_data , io_control }
 
enum class  message_type : uint32_t {
  error_response = 0 , query_storage_request , query_storage_response , init_storage_request ,
  init_storage_response , create_rdma_connection_request , create_rdma_connection_response , start_storage_request ,
  start_storage_response , stop_storage_request , stop_storage_response , shutdown_request ,
  shutdown_response
}
 

Functions

std::unique_ptr< storage::control::comch_channelmake_comch_client_control_channel (doca_dev *dev, char const *channel_name, void *callback_user_data, comch_channel::consumer_event_callback new_consumer_event_cb, comch_channel::consumer_event_callback expired_consumer_event_cb)
 
std::unique_ptr< storage::control::comch_channelmake_comch_server_control_channel (doca_dev *dev, doca_dev_rep *dev_rep, char const *channel_name, void *callback_user_data, comch_channel::consumer_event_callback new_consumer_event_cb, comch_channel::consumer_event_callback expired_consumer_event_cb)
 
std::unique_ptr< storage::control::channelmake_tcp_client_control_channel (storage::ip_address const &server_address)
 
std::unique_ptr< storage::control::channelmake_tcp_server_control_channel (uint16_t listen_port)
 
uint32_t wire_size (storage::control::message_header const &hdr) noexcept
 
uint32_t wire_size (storage::control::message const &msg)
 
char * encode (char *buffer, storage::control::message_header const &hdr) noexcept
 
char * encode (char *buffer, storage::control::message const &msg)
 
char const * decode (char const *buffer, storage::control::message_header &hdr) noexcept
 
char const * decode (char const *buffer, storage::control::message &msg)
 
std::string to_string (storage::control::message_type type)
 
std::string to_string (storage::control::rdma_connection_role role)
 
std::string to_string (storage::control::message const &msg)
 
bool operator== (message_id const &lhs, message_id const &rhs)
 

Enumeration Type Documentation

◆ message_type

enum storage::control::message_type : uint32_t
strong
Enumerator
error_response 
query_storage_request 
query_storage_response 
init_storage_request 
init_storage_response 
create_rdma_connection_request 
create_rdma_connection_response 
start_storage_request 
start_storage_response 
stop_storage_request 
stop_storage_response 
shutdown_request 
shutdown_response 

Definition at line 56 of file control_message.hpp.

◆ rdma_connection_role

Enumerator
io_data 
io_control 

Definition at line 38 of file control_message.hpp.

Function Documentation

◆ decode() [1/2]

char const * storage::control::decode ( char const *  buffer,
storage::control::message msg 
)

Definition at line 185 of file control_message.cpp.

◆ decode() [2/2]

char const * storage::control::decode ( char const *  buffer,
storage::control::message_header hdr 
)
noexcept

Definition at line 180 of file control_message.cpp.

◆ encode() [1/2]

char * storage::control::encode ( char *  buffer,
storage::control::message const &  msg 
)

Definition at line 112 of file control_message.cpp.

◆ encode() [2/2]

char * storage::control::encode ( char *  buffer,
storage::control::message_header const &  hdr 
)
noexcept

Definition at line 107 of file control_message.cpp.

◆ make_comch_client_control_channel()

std::unique_ptr< storage::control::comch_channel > storage::control::make_comch_client_control_channel ( doca_dev *  dev,
char const *  channel_name,
void *  callback_user_data,
comch_channel::consumer_event_callback  new_consumer_event_cb,
comch_channel::consumer_event_callback  expired_consumer_event_cb 
)

Definition at line 762 of file control_channel.cpp.

◆ make_comch_server_control_channel()

std::unique_ptr< storage::control::comch_channel > storage::control::make_comch_server_control_channel ( doca_dev *  dev,
doca_dev_rep *  dev_rep,
char const *  channel_name,
void *  callback_user_data,
comch_channel::consumer_event_callback  new_consumer_event_cb,
comch_channel::consumer_event_callback  expired_consumer_event_cb 
)

Definition at line 776 of file control_channel.cpp.

◆ make_tcp_client_control_channel()

std::unique_ptr< storage::control::channel > storage::control::make_tcp_client_control_channel ( storage::ip_address const &  server_address)

Definition at line 792 of file control_channel.cpp.

◆ make_tcp_server_control_channel()

std::unique_ptr< storage::control::channel > storage::control::make_tcp_server_control_channel ( uint16_t  listen_port)

Definition at line 797 of file control_channel.cpp.

◆ operator==()

bool storage::control::operator== ( message_id const &  lhs,
message_id const &  rhs 
)
inline

Definition at line 47 of file control_message.hpp.

◆ to_string() [1/3]

std::string storage::control::to_string ( storage::control::message const &  msg)

Definition at line 285 of file control_message.cpp.

◆ to_string() [2/3]

std::string storage::control::to_string ( storage::control::message_type  type)

Definition at line 239 of file control_message.cpp.

◆ to_string() [3/3]

std::string storage::control::to_string ( storage::control::rdma_connection_role  role)

Definition at line 273 of file control_message.cpp.

◆ wire_size() [1/2]

uint32_t storage::control::wire_size ( storage::control::message const &  msg)

Definition at line 39 of file control_message.cpp.

◆ wire_size() [2/2]

uint32_t storage::control::wire_size ( storage::control::message_header const &  hdr)
noexcept

Definition at line 33 of file control_message.cpp.