admin管理员组文章数量:1391998
I am using mass transit 7.3.1 with mass transit simple injector for sending msgs to rabbit mq and upon using the method IPublishEndpoint.Publish
(Task Publish<T>(object values, CancellationToken cancellationToken = default(CancellationToken)) where T : class;
it throws the exception
Exception: "System.ObjectDisposedException: The CancellationTokenSource has been disposed.\n at MassTransit.Conte │ │ xt.BaseReceiveContext.get_CancellationToken()\n at MassTransit.Context.MessageConsumeContext
1.GreenPipes.PipeContext.get_CancellationToken()\n at MassTransit.Context.ConsumeContextScope.get_Cancellati │ │ onToken()\n at MassTransit.Context.ConsumeContextScope.get_CancellationToken()\n at GreenPipes.ProxyPipeContext.get_CancellationToken()\n at GreenPipes.ProxyPipeContext.get_CancellationToken()\n at │ │ GreenPipes.ProxyPipeContext.get_CancellationToken()\n at MassTransit.Initializers.MessageInitializer
2.Send(ISendEndpoint endpoint, InitializeContext`1 context, Object input)
I have tried passing the cancellation token within a using statement and also have tried passing CancellationToken.None
. But neither has helped.
Any ideas?
本文标签:
版权声明:本文标题:rabbitmq - MassTransit 7.3.1 Publish method exception: "System.ObjectDisposedException: The CancellationTokenSource has 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744720594a2621670.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论