Skip to content

Add Completion on _waitForConfirmationActionBlock #298

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

Merged
merged 3 commits into from
Sep 19, 2023
Merged

Conversation

Gsantomaggio
Copy link
Member

@Gsantomaggio Gsantomaggio commented Sep 14, 2023

exceptions.StackTraceString: at 
System.Threading.Tasks.Dataflow.DataflowBlock.SendAsync[TInput](ITargetBlock`1
 target, TInput item, CancellationToken cancellationToken)
   at 
RabbitMQ.Stream.Client.Reliable.ProducerFactory.<StandardProducer>b__4_2(Confirmation
 confirmation) in 
/_/RabbitMQ.Stream.Client/Reliable/ProducerFactory.cs:line 99
   at 

The line: ProducerFactory.cs:line 99 is what sends the confirmation of the messages to the user callback

_confirmationPipe.RemoveUnConfirmedMessage(confirmationStatus, confirmation.PublishingId,

That would explain why you don't receive the notification anymore.

The PR adds the TLS certificates for Kubernetes only for testing.

@ricardSiliuk @ricsiLT if you have the opportunity to test let us know.
Thank you

To wait _waitForConfirmationActionBlock.SendAsync in case is not completed
Add an exception handler on the ConfirmHandler since the code could raise an
exception user side.
That is for #295

Add the tls configurtation for the k8s cluster.

Signed-off-by: Gabriele Santomaggio <[email protected]>
@codecov
Copy link

codecov bot commented Sep 14, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.09% 🎉

Comparison is base (c8e3726) 92.87% compared to head (38dc658) 92.97%.

❗ Current head 38dc658 differs from pull request most recent head 66d6c90. Consider uploading reports for the commit 66d6c90 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #298      +/-   ##
==========================================
+ Coverage   92.87%   92.97%   +0.09%     
==========================================
  Files         112      112              
  Lines        9689     9706      +17     
  Branches      771      773       +2     
==========================================
+ Hits         8999     9024      +25     
+ Misses        528      521       -7     
+ Partials      162      161       -1     
Files Changed Coverage Δ
RabbitMQ.Stream.Client/RawProducer.cs 88.30% <100.00%> (+2.28%) ⬆️
...abbitMQ.Stream.Client/Reliable/ConfirmationPipe.cs 100.00% <100.00%> (ø)
RabbitMQ.Stream.Client/Reliable/ProducerFactory.cs 100.00% <100.00%> (ø)

... and 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Stream = _config.Stream
});
}
catch (Exception e)
Copy link
Member Author

Choose a reason for hiding this comment

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

As written in the comment The call is exposed to the user, so we need to catch any exception there could be an exception in the user code. we need to trap Exception to avoid blocking the iteration.

@Gsantomaggio Gsantomaggio marked this pull request as ready for review September 18, 2023 14:31
@Gsantomaggio Gsantomaggio merged commit 301afb5 into main Sep 19, 2023
@Gsantomaggio Gsantomaggio deleted the issue_293 branch September 19, 2023 08:53
@Gsantomaggio Gsantomaggio added this to the 1.7.1 milestone Sep 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants