| Crates.io | rabbitmesh |
| lib.rs | rabbitmesh |
| version | 0.1.1 |
| created_at | 2025-08-28 09:42:45.606718+00 |
| updated_at | 2025-08-30 12:00:20.378542+00 |
| description | Message-driven microservices framework using RabbitMQ for zero-port service mesh |
| homepage | https://github.com/rabbitmesh/rabbitmesh |
| repository | https://github.com/rabbitmesh/rabbitmesh |
| max_upload_size | |
| id | 1813866 |
| size | 157,531 |

Zero-Port Microservices Framework
Write business logic, get REST + GraphQL APIs automatically
RabbitMesh eliminates traditional microservice complexity by using RabbitMQ for all inter-service communication. Write business logic, get REST + GraphQL APIs automatically.
use rabbitmesh_macros::{service_definition, service_method};
#[service_definition]
pub struct UserService;
impl UserService {
#[service_method("GET /users/:id")]
pub async fn get_user(user_id: u32) -> Result<User, String> {
// Your business logic only
Ok(User { id: user_id, name: "John".to_string() })
}
#[service_method("POST /users")]
pub async fn create_user(data: CreateUserRequest) -> Result<User, String> {
// Handle user creation
Ok(User { id: 1, name: data.name })
}
}
use rabbitmesh::MicroService;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let service = MicroService::new("amqp://localhost:5672").await?;
service.start().await?; // Never blocks, handles requests concurrently
Ok(())
}
use rabbitmesh_gateway::create_auto_router;
#[tokio::main]
async fn main() {
let app = create_auto_router().await;
// Automatically provides:
// GET /api/v1/user-service/users/123
// POST /api/v1/user-service/users
// GraphQL endpoint at /graphql
axum::Server::bind(&"0.0.0.0:3000".parse().unwrap())
.serve(app.into_make_service())
.await
.unwrap();
}
βββββββββββββββ βββββββββββββββ βββββββββββββββββββββββββββββββββββ
β Frontend ββββββ API Gateway ββββββ Service Mesh β
β (NextJS) βHTTPβ (Auto-Gen) βAMQPβ βββββββ βββββββ βββββββ β
β β β β β βUser β βAuth β βOrderβ ... β
βββββββββββββββ βββββββββββββββ β βββββββ βββββββ βββββββ β
β β β
β βββββββββββββββ β
β β RabbitMQ β β
β β Broker β β
βββββββ΄ββββββββββββββ΄βββββββββββββ
rabbitmesh - Core microservice frameworkrabbitmesh-macros - Code generation macrosrabbitmesh-gateway - Auto-generating API gatewayexamples/ecommerce - Complete demo application| Traditional HTTP | RabbitMesh |
|---|---|
| β Port management hell | β Zero ports to manage |
| β Manual load balancing | β Automatic via RabbitMQ |
| β Service discovery complexity | β Auto-discovery via queues |
| β Blocking request handlers | β Every request is async |
| β Manual API development | β Auto-generated REST + GraphQL |
See the examples/simple-todo directory for a complete working example, or use our AI agent to create new projects:
# Install the AI agent and create a new project
python3 rabbitmesh_agent.py create my-awesome-service
We welcome contributions! Please see our Contributing Guide for details.
MIT license. See LICENSE for details.

Built with β€οΈ by the RabbitMesh Team
π¦ Crates.io β’ π Docs β’ π GitHub β’ π¬ Discussions
The future of microservices is here - zero ports, maximum power, pure elegance β¨