Function wireman_core::client::call_unary_blocking

source ·
pub fn call_unary_blocking(
    req: &RequestMessage,
    tls_config: Option<TlsConfig>,
) -> Result<ResponseMessage>
Expand description

Creates a new gRPC client and sends a message to a gRPC server. This method is blocking.

§Errors

  • Internal error calling the gRPC server
Examples found in repository?
examples/metadata.rs (line 31)
29
30
31
32
33
pub fn do_request(req: &RequestMessage) -> Result<ResponseMessage> {
    let tls_config = TlsConfig::native()?;
    let resp = call_unary_blocking(req, Some(tls_config))?;
    Ok(resp)
}