npm @nestjs-plugins/nestjs-nats-jetstream-transport 2.3.0
nestjs-nats-jetstream-transport 2.3.0

latest releases: 2.4.0, 2.3.1
one hour ago

@nestjs-plugins/nestjs-nats-jetstream-transport@2.3.0. Existing code needs no changes.

npm i @nestjs-plugins/nestjs-nats-jetstream-transport@^2.3.0

Requires Node.js 22 or later. If you are on an older Node version, stay on 2.2.x.

Features

  • eventHandlerError (server, optional): decides what happens to a message when its @EventPattern handler fails.
    • { action: 'term' } stops redelivery.
    • { action: 'nak', nakDelay?: ms } redelivers the message, after the delay if one is given.
    • When the option is not set, behavior is the same as before. The message is left unsettled, so with manualAck it is redelivered after ackWait. See the README section "Handling event handler errors".
  • jetStreamOptions (client): this option name, which the README already documented, now takes effect. jetStreamOption still works and is deprecated.

Bug fixes

  • close() on the server and client no longer throws when there is no connection. NestJS 8 calls close() twice on shutdown, which used to throw.
  • A request/reply payload that is not valid JSON gets an error reply at once. Previously the caller waited for its timeout and an unhandled rejection escaped.
  • Stream setup reads every page of the stream list, so an existing stream beyond the first page is updated instead of failing to be re-created.

Other

  • Unit and integration tests, and CI on Node 22 and 24.
  • The published type declarations now keep their JSDoc.

Full changelog: CHANGELOG.md · PR #71

Don't miss a new nestjs-nats-jetstream-transport release

NewReleases is sending notifications on new releases.