Skip to content

Consolidated into #3311 to keep the related Redis and NATS changes in one PR. - #3315

Closed
DMINQ wants to merge 1 commit into
ag2ai:mainfrom
DMINQ:feat/nats-jstream-destinations
Closed

DMINQ wants to merge 1 commit into
ag2ai:mainfrom
DMINQ:feat/nats-jstream-destinations

Conversation

@DMINQ

@DMINQ DMINQ commented Oct 30, 2026

Copy link
Copy Markdown

Description

Allow NatsBroker.publish() and NatsBroker.request() to accept a JStream
object as the stream argument, alongside existing string names.

Normalize the object to its name before producer selection and middleware
execution. The target subject remains a separate argument, and sending
does not modify or declare the supplied stream.

Update return-type overloads, tests, and documentation.

Related to #3305.

Type of change

  • New feature (a non-breaking change that adds functionality)
  • Documentation update

Validation

  • Real NATS with JetStream: publish delivery, PubAck stream name,
    and request/reply correlation checked for string and JStream arguments.
  • Both object cases failed before implementation; all four cases passed after.
  • Test-client and request-cleanup tests passed.
  • Documentation example test and documentation checks passed.
  • Ruff, mypy, Pyright, and Pyrefly passed.

@github-actions github-actions Bot added documentation Improvements or additions to documentation NATS Issues related to `faststream.nats` module and NATS broker features labels Oct 30, 2026
@DMINQ DMINQ changed the title feat(nats): accept JStream objects in broker methods Consolidated into #3311 to keep the related Redis and NATS changes in one PR. Oct 31, 2026
@DMINQ DMINQ closed this Oct 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation NATS Issues related to `faststream.nats` module and NATS broker features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant