13 m_srv(std::move(srv)) {
14 m_srv->register_handler_callback(
17 auto res = std::visit(
Generic asynchronous RPC server.
Interface for an asynchronous sentinel.
std::function< void(std::optional< cbdc::sentinel::response >)> result_callback_type
Callback function for a sentinel response.
virtual auto validate_transaction(transaction::full_tx tx, validate_result_callback_type result_callback) -> bool=0
Statically validate the given transaction and generate a sentinel attestation if the transaction is v...
virtual auto execute_transaction(transaction::full_tx tx, execute_result_callback_type result_callback) -> bool=0
Validate transaction on the sentinel, forward it to the coordinator network, and return the execution...
async_server(async_interface *impl, std::unique_ptr< cbdc::rpc::async_server< request, response > > srv)
Constructor.
std::variant< execute_request, validate_request > request
Sentinel RPC request type.
Variant handler template.
Sentinel request message.
Request type for transaction validation and attestation.