Rust Grpc Services
# Rust gRPC Services with Tonic
## Objective
Build high-performance gRPC microservices in Rust using Tonic framework. The implementation must leverage Rust's zero-cost abstractions, memory safety, and concurrency primitives for maximum throughput and reliability.
---
## Core Requirements
### Performance Targets
- **Latency**: p99 under 5ms for unary calls
- **Throughput**: 100,000+ requests/second per core
- **Memory**: Predictable memory usage with no garbage collection pauses
- **Concurrency**: Efficient async/await with Tokio runtime
- **Type Safety**: Compile-time guarantees for protocol correctness
---
## Technology Stack
- **gRPC Framework**: Tonic v0.11+
- **Async Runtime**: Tokio v1.35+
- **Serialization**: Protocol Buffers (protobuf)
- **Database**: sqlx for PostgreSQL with compile-time query verification
- **Tracing**: tracing + tracing-subscriber for structured logging
- **Metrics**: prometheus-client for metrics export
---
## Project Structurewhen to use it
Community prompt sourced from the open-source GitHub repo Dziqha/awesome-agentic-coding-prompts (MIT). A "Rust Grpc Services" style prompt — adapt the placeholders and specifics to your task. Imported as-is and not independently retested here, so check the output before relying on it.
tags
roleplaycommunitygeneral
source
Dziqha/awesome-agentic-coding-prompts · MIT