Quantcast
Channel: Service Bus forum
Viewing all articles
Browse latest Browse all 1916

BrokeredMessage.CompleteAsync always gives ObjectDisposedException

$
0
0

message.CompleteAsync().ContinueWith(tr =>
                    {
                        if (tr.Exception != null)
                        {                       
                            Trace.TraceWarning("Failed to Complete BrokeredMessage \n" + tr.Exception.ToString());
                        }
                    });

--------------------------------------

Failed to Complete BrokeredMessage 
System.AggregateException: One or more errors occurred. ---> System.ObjectDisposedException: BrokeredMessage has been disposed.
   at Microsoft.ServiceBus.Messaging.BrokeredMessage.ThrowIfDisposed()
   at Microsoft.ServiceBus.Messaging.BrokeredMessage.EndComplete(IAsyncResult result)
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)
   --- End of inner exception stack trace ---
---> (Inner Exception #0) System.ObjectDisposedException: BrokeredMessage has been disposed.
   at Microsoft.ServiceBus.Messaging.BrokeredMessage.ThrowIfDisposed()
   at Microsoft.ServiceBus.Messaging.BrokeredMessage.EndComplete(IAsyncResult result)
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)<---


Viewing all articles
Browse latest Browse all 1916

Trending Articles