Trait re_protos::sdk_comms::v0::message_proxy_server::MessageProxy
source · pub trait MessageProxy: Send + Sync + 'static {
type ReadMessagesStream: Stream<Item = Result<LogMsg, Status>> + Send + 'static;
// Required methods
fn write_messages<'life0, 'async_trait>(
&'life0 self,
request: Request<Streaming<LogMsg>>,
) -> Pin<Box<dyn Future<Output = Result<Response<Empty>, Status>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn read_messages<'life0, 'async_trait>(
&'life0 self,
request: Request<Empty>,
) -> Pin<Box<dyn Future<Output = Result<Response<Self::ReadMessagesStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}
Expand description
Generated trait containing gRPC methods that should be implemented for use with MessageProxyServer.
Required Associated Types§
Required Methods§
sourcefn write_messages<'life0, 'async_trait>(
&'life0 self,
request: Request<Streaming<LogMsg>>,
) -> Pin<Box<dyn Future<Output = Result<Response<Empty>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn write_messages<'life0, 'async_trait>(
&'life0 self,
request: Request<Streaming<LogMsg>>,
) -> Pin<Box<dyn Future<Output = Result<Response<Empty>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
TODO(jan): Would it be more efficient to send a “message batch” instead of individual messages? It may allow us to amortize the overhead of the gRPC protocol.