userver: ugrpc Namespace Reference
⚠️ This is the documentation for an old userver version. Click here to switch to the latest version.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages Concepts
ugrpc Namespace Reference

Asynchronous gRPC driver. More...

Namespaces

namespace  client
 Client-side utilities.
 
namespace  server
 Server-side utilities.
 

Functions

formats::json::Value MessageToJson (const google::protobuf::Message &message)
 Returns formats::json::Value representation of protobuf message.
 
std::string ToString (const google::protobuf::Message &message)
 Converts message to human readable string.
 
std::string ToJsonString (const google::protobuf::Message &message)
 Returns Json-string representation of protobuf message.
 
grpc::StatusCode StatusCodeFromString (std::string_view str)
 Convert string to grpc::StatusCode.
 
std::string_view ToString (grpc::StatusCode code) noexcept
 Convert grpc::StatusCode to string.
 

Detailed Description

Asynchronous gRPC driver.

Function Documentation

◆ MessageToJson()

formats::json::Value ugrpc::MessageToJson ( const google::protobuf::Message &  message)

Returns formats::json::Value representation of protobuf message.

Exceptions
SerializationError

◆ StatusCodeFromString()

grpc::StatusCode ugrpc::StatusCodeFromString ( std::string_view  str)

Convert string to grpc::StatusCode.

Exceptions
std::runtime_error

◆ ToJsonString()

std::string ugrpc::ToJsonString ( const google::protobuf::Message &  message)

Returns Json-string representation of protobuf message.

Exceptions
formats::json::ConversionException