What problem does it solve?
Inconsistent or incorrect gRPC proto files and service implementations that leak business logic, use improper proto types for nullability and timestamps, and lack consistent mapping to domain models are common sources of bugs and runtime errors in .NET microservices.
Core Features & Use Cases
- Proto-first service contracts: Guidance for structuring command and query proto files with clear naming and package conventions.
- Clean service implementations: Patterns for inheriting generated Base classes and delegating work to MediatR handlers.
- Mapping & types: Best practices for mapping extensions, using google.protobuf wrappers for nullable fields and timestamp handling for DateTime.
- Registration & runtime: Instructions for registering GRPC services, interceptors, and pagination message patterns.
- Use Case: Create OrderCommands and OrderQueries proto files, generate C# stubs, add mapping extensions, and register services so the application delegates business logic to MediatR handlers.
Quick Start
Generate proto templates and C# gRPC service stubs for an Order domain with MediatR-based handlers.