Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Publisher Confirms from RMQ #1494

Merged
merged 7 commits into from
May 5, 2021
Merged

Support Publisher Confirms from RMQ #1494

merged 7 commits into from
May 5, 2021

Conversation

iancooper
Copy link
Member

We did the hard work for this under two other changes:

  • Outbox support, particularly the in-memory support so Outbox is always on, which simplifies use of it by producers.
  • Kafka producers, which always work by asynchronous confirmation of the message being posted, and therefore tying them to an Outbox to ensure we actually send becomes fairly critical.

At that point it became fairly easy to plug RQM confirms into this model. it just needs to support the right interface and raise the event when it receives confirmation that the message has been published

Closes#275

@iancooper iancooper self-assigned this Apr 22, 2021
@iancooper iancooper linked an issue Apr 22, 2021 that may be closed by this pull request
@@ -74,7 +73,7 @@ public RmqMessageProducerConfrmationsSendMessageTests ()
[Fact]
public async Task When_confirming_posting_a_message_via_the_messaging_gateway()
{
_messageProducer.Send(_message);
await _messageProducer.SendAsync(_message);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't support SendAsync on an RMQ producer as there is no Async method on RMQ. I'll revert then patch a fix to use a taskcompletion source so at least that code path won't throw for now

@iancooper
Copy link
Member Author

@holytshirt I fixed that issue around the TaskCompletionSource for SendAsync on the RMQ message producer. Any more actions you would like to see, or move this one into master?

@holytshirt holytshirt merged commit b7cedb7 into master May 5, 2021
honkuan86 added a commit to honkuan86/Brighter that referenced this pull request May 6, 2021
@iancooper iancooper deleted the publisher_confirms branch October 11, 2021 17:14
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.

Support publisher confirms in RMQ
2 participants