开发者

Unable to cast object of type 'MyService.EndpointConfig' to type 'NServiceBus.Host.IConfigureThisEndpoint'

开发者 https://www.devze.com 2022-12-15 23:03 出处:网络
I have a problem with NServiceBus: I have defined an endpoint config that implements IConfigureThisEndpoint, but when I 开发者_如何学Pythonrun the service with a generic host, it complains that the ty

I have a problem with NServiceBus: I have defined an endpoint config that implements IConfigureThisEndpoint, but when I 开发者_如何学Pythonrun the service with a generic host, it complains that the type cannot be cast to the namespace. Any idea why?


Sounds to me that you have "EndpointConfigurationType" specified in the config file. Can you verify is that is true, if so try to remove it and see if it solves your problem?


As it turns out, there are two namespaces called IConfigureEndpoint in NServiceBus. I was using the wrong one - had to reference the ServiceHost EXE instead.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号