Skip to content

Implement message type binding for receive endpoints and enhance error handling#9870

Draft
PascalSenn wants to merge 2 commits into
mainfrom
pse/all-endpoint-to-receive
Draft

Implement message type binding for receive endpoints and enhance error handling#9870
PascalSenn wants to merge 2 commits into
mainfrom
pse/all-endpoint-to-receive

Conversation

@PascalSenn

Copy link
Copy Markdown
Member
  • Added Receives<TMessage>() and Receives(Type messageType) methods to endpoint descriptors for binding handlers by message type.
  • Updated MessagingTransport to utilize the new binding methods and throw exceptions when no handler is registered for a message type.
  • Introduced tests to validate the new binding behavior and error handling.
  • Updated documentation to reflect the new binding approach for message types.

…r handling

- Added `Receives<TMessage>()` and `Receives(Type messageType)` methods to endpoint descriptors for binding handlers by message type.
- Updated `MessagingTransport` to utilize the new binding methods and throw exceptions when no handler is registered for a message type.
- Introduced tests to validate the new binding behavior and error handling.
- Updated documentation to reflect the new binding approach for message types.
Address devil's-advocate review of Receives<T> binding:
- BindRouteToEndpoint now copies the source route's Condition onto the
  fan-out clone, so custom filters and saga typed-reply guards are no
  longer widened to a default condition.
- Add an idempotency guard so declaring the same message type or
  consumer across three or more endpoints does not over-clone routes.

Add regression tests: condition preservation on fan-out, no duplicate
routes across three endpoints, and behavioral delivery to both queues.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant