You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pulsar.apache.org by GitBox <gi...@apache.org> on 2020/09/02 13:26:51 UTC

[GitHub] [pulsar-dotpulsar] lee-chrisbell commented on a change in pull request #52: Eat errors in SetupChannel

lee-chrisbell commented on a change in pull request #52:
URL: https://github.com/apache/pulsar-dotpulsar/pull/52#discussion_r482066998



##########
File path: src/DotPulsar/Internal/ConsumerProcess.cs
##########
@@ -84,8 +84,15 @@ protected override void CalculateState()
 
         private async void SetupChannel()
         {
-            var channel = await _factory.Create(CancellationTokenSource.Token).ConfigureAwait(false);
-            await _consumer.SetChannel(channel).ConfigureAwait(false);
+            try
+            {
+                var channel = await _factory.Create(CancellationTokenSource.Token).ConfigureAwait(false);
+                await _consumer.SetChannel(channel).ConfigureAwait(false);
+            }
+            catch (Exception ex)
+            {
+                Console.WriteLine($"Setup Channel failed for Consumer \n {ex.ToString()}");

Review comment:
       Yeah, good point. Changed it.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org