Search code examples
asp.net-core-webapinservicebus

NServiceBus IP Address


I am new to Nservicebus and have recently started working in it. I am stuck on a point and need input from you guys. I have 2 asp.net core web api projects and I want to use NServicebus to send messages between both of them in some scenarios.

What I have found so far that I can provide name to EndpointConfiguration, what if one of my api is deployed on 1 server and 2nd on another server, in that case how my configuration should be?

I tried to gave url instead of name in EndpointConfiguration but it gave me exception.

Thanks in advance for your help


Solution

  • NServiceBus endpoints communicate over some messaging infrastructure your system will be using. Endpoint names represent queues messages sent to. Messaging infrastructure is abstracted by what NServiceBus is calling a Transport. You will need to decide on the transport you'd like to use (see the options here). Once you've decided what transport your solution will use, you could have a look at the samples for that specific transports to have an idea how to set up your endpoints.

    For example, if you'll decide to use Azure Service Bus as your transport, you could download and try the Send/Reply sample.

    A good starting point could be the tutorials available on the documentation site here.