npm / @nestjs/microservices
@nestjs/microservices
What changed in @nestjs/microservices 11 to 12, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-01.
5 breaking9 security4 new APIs and options
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli init@nestjs/microservices 1212 changes
Breaking changes 5
NATS v3 dropped the JSONCodec helper, so applications using it must update their NATS code.
Custom NATS deserializers now receive the full NATS message object instead of a raw Uint8Array; read the payload with msg.json().
The NATS transport now targets NATS v3; replace the old nats package with @nats-io/transport-node.
Nest now serializes NATS packets as JSON strings, affecting applications that depend on the previous serialization format.
NATS v3 dropped the StringCodec helper, so applications using it must update their NATS code.
Security 3
Nest: Unbounded memory growth in the NestJS TCP microservice transport
Nest: Remote process termination via a deeply nested microservice message pattern
@nestjs/platform-fastify: Path-scoped middleware bypass via absolute-form request targets
New APIs and options 4
The Kafka transport now accepts a RegExp for @EventPattern(), enabling regular-expression patterns.
GrpcExceptionFilter and status-specific exceptions map errors to the proper gRPC status codes instead of UNKNOWN.
The Kafka transport now accepts a RegExp for @MessagePattern(), enabling regular-expression patterns.
A new hook runs before a microservice message handler is invoked.
@nestjs/microservices 116 changes
Security 6
Nest: Middleware Bypass on Fastify via Trailing Slash
Nest Affected by DoS via Recursive handleData in JsonSocket (TCP Transport)
@nestjs/core Improperly Neutralizes Special Elements in Output Used by a Downstream Component ('Injection')
Nest Fastify HEAD Request Middleware Bypass
Nest has a Fastify URL Encoding Middleware Bypass
Nest has a Fastify URL Encoding Middleware Bypass (TOCTOU)