Skip to main content

Module transcode

Module transcode 

Source
Expand description

REST→gRPC transcoding layer.

Reads google.api.http annotations from proto service descriptors and builds axum routes that proxy JSON/form requests to gRPC upstream.

Generic: works with ANY proto descriptor set. No product-specific code.

Modules§

body
Request body parsing.
codec
Dynamic gRPC codec for prost-reflect::DynamicMessage.
error
gRPC → HTTP error mapping.
metadata
HTTP → gRPC metadata, trace-context, and deadline propagation.
request
Request message construction for REST→gRPC transcoding.

Traits§

TranscodeState
Trait for state types that support REST→gRPC transcoding.

Functions§

proto_path_to_axum
Convert a google.api.http path template to axum 0.8 path syntax.
routes
Build transcoded REST→gRPC routes from a descriptor pool.