API Gateway (RabbitMQ)
NestJS API Gateway routing HTTP requests to microservices via RabbitMQ.
Role
Implementer ImplementadorProblem
External clients need REST while internal services should communicate only through the message bus. Clientes externos necesitan REST mientras servicios internos deben comunicarse solo por el bus de mensajes.Impact
Thin HTTP edge translating requests to RabbitMQ RPC — hides topology from API consumers. Edge HTTP delgado traduciendo requests a RPC RabbitMQ — oculta topología a consumidores del API.Technical stack
Layer-by-layer breakdown of subsystems, repositories, and production concerns.
HTTP API edge Borde HTTP del API
Single public NestJS app exposing REST routes — validates input and maps to internal message contracts. App NestJS pública única exponiendo rutas REST — valida entrada y mapea a contratos de mensajes internos.
- One front door for external clients Una puerta de entrada para clientes externos
RabbitMQ request routing Enrutamiento de requests RabbitMQ
ClientProxy sends RPC-style messages to users and transactions queues and awaits correlated responses. ClientProxy envía mensajes estilo RPC a colas de users y transactions y espera respuestas correlacionadas.
- Hides microservice topology from callers Oculta topología de microservicios a los callers
Auth & error mapping Auth y mapeo de errores
JWT validation at the edge; downstream failures translated to consistent HTTP status codes. Validación JWT en el edge; fallos downstream traducidos a códigos HTTP consistentes.
- Thin gateway — no business logic in the edge layer Gateway delgado — sin lógica de negocio en el edge
Microservices ecosystem Ecosistema de microservicios
Part of a three-repo demo with users and transactions services — reference for NestJS + RabbitMQ learning. Parte de un demo de tres repos con servicios users y transactions — referencia para aprender NestJS + RabbitMQ.
- Composable with nestjs-microservices-transactions-rabbitmq Composable con nestjs-microservices-transactions-rabbitmq
Related topics
Explore curated hubs that connect this work with case studies, articles, and learning repos.