Skip to main content

Module tonic

Module tonic 

Source
Expand description

gRPC service implementation

Thin wrapper around shared handler functions from the handlers module. All business logic is in handlers, this just adapts to the tonic interface.

Structs§

ConsensusServiceImpl
gRPC consensus service implementation wrapping a ConsensusApi implementation
DataServiceImpl
gRPC data service implementation wrapping a DataApi implementation
RewardServiceImpl
gRPC reward service implementation wrapping a RewardApi implementation

Functions§

create_consensus_service
Create the consensus gRPC service
create_data_service
Create the data gRPC service
create_reward_service
Create the reward gRPC service
map_error 🔒
Convert ApiError to tonic::Status with proper status code mapping