For detailed per-crate documentation, see the CLAUDE.md in each sub-crate directory.
Volo is a high-performance Rust RPC framework by CloudWeGo (ByteDance). It supports Thrift, gRPC, and HTTP protocols with fully async design (Tokio), zero-copy optimizations, and middleware via Service/Layer abstractions (motore).
- Rust Edition: 2024
- MSRV: 1.85.0
- Current Version: 0.12.x
volo/
├── volo/ # Core library
├── volo-build/ # Code generation from IDL (Thrift/Protobuf)
├── volo-cli/ # CLI tool (project scaffolding)
├── volo-grpc/ # gRPC implementation
├── volo-http/ # HTTP implementation
├── volo-macros/ # Procedural macros (reserved)
├── volo-thrift/ # Thrift implementation
├── examples/ # Example code
├── benchmark/ # Performance benchmarks
└── tests/code-generation/ # Code generation tests
volo-macros (reserved)
|
v
+------------------ volo ------------------+
| | |
v v v
volo-thrift volo-grpc volo-http
| | |
+----------+----------+ |
v |
volo-build <----------------------------+
|
v
volo-cli
- volo: Core abstractions -- service discovery (
Discover), load balancing (LoadBalance), network transport (Address,Conn, TCP/Unix/TLS/ShmIPC), context (RpcCx,RpcInfo,Endpoint), hot restart, panic capture - volo-thrift: TTHeader/Framed transport, Binary/Compact protocols, Ping-Pong/Multiplex modes, connection pooling, ISN-based multi-service routing, BizError
- volo-grpc: HTTP/2 (hyper), unary/streaming calls, compression (gzip/zlib/zstd), gRPC-Web, metadata
- volo-http: Server (Router/Handler/Extractor), Client (connection pooling/DNS/proxy), JSON/Form/Multipart/WebSocket/SSE, TLS (Rustls/Native-TLS)
- volo-build: Generates Rust code from Thrift/Protobuf IDL. Config:
volo.yml/volo.workspace.yml - volo-cli:
volo init,volo http init,volo idl add,volo repo add/update,volo migrate - volo-macros: Reserved. Active macros:
#[service](from motore),volo_unreachable!,new_type!(from volo)
| Feature | volo | volo-thrift | volo-grpc | volo-http |
|---|---|---|---|---|
rustls |
Y | - | Y | Y |
native-tls |
Y | - | Y | Y |
shmipc |
Y | Y | - | - |
multiplex |
- | Y | - | - |
gzip/zlib |
- | - | Y(default) | - |
zstd |
- | - | Y | - |
grpc-web |
- | - | Y | - |
json |
- | - | - | Y(default) |
ws |
- | - | - | Y |
cookie |
- | - | - | Y |
All built on the motore crate's Service<Cx, Request> and Layer<S> traits.
- Service Discovery:
Discovertrait (volo) --StaticDiscover,WeightedStaticDiscover - Load Balancing:
LoadBalancetrait (volo) -- weighted random, consistent hashing
- Builder:
XxxBuilder::new().xxx().build() - Make:
MakeXxxtrait createsXxxinstances - Layer:
XxxLayerimplementsmotore::layer::Layer - Service: Implements
motore::service::Service - Private features: Prefixed with
__(e.g.,__tls)
Follow Conventional Commits: feat(volo-thrift): add multi-service support, fix(volo-http): resolve connection pool leak, chore: update dependencies
Publish in this order:
volo-macrosvolovolo-buildvolo-clivolo-thriftvolo-grpcvolo-http(released independently)