No service for type 'NServiceBus.ReceiveAddresses' has been registered

I am in the process of upgrading a process from NSB 7.X to 8.0.3 and I have fixed all of the compile errors and now when I make the following call I receive an exception:

No service for type ‘NServiceBus.ReceiveAddresses’ has been registered

I am using the SqlServer transport version 7.0.0

Any ideas as to what I am missing?

1 Like

Hi @ssmall ,

You most likely get this type of exceptions when you’re passing a IServiceProvider to the Start method that isn’t built based on the IServiceCollection that you passed to EndpointWithExternallyManagedContainer.Create.

Is there a specific reason you’re using the externally managed container mode? I’d recommend to use the Microsoft generic host integration (NServiceBus.Extensions.Hosting • Particular Docs) if you need to use an externally managed DI container.