In this chapter, we dissected the process of hosting and configuring an NServiceBus endpoint both using the NServiceBus Host and in our own application. We now know how to select a message transport, persistence strategy, message serializer, and quite a few other options as well.
At this point, you may be thinking that there are a lot of settings that will need to be repeated for every single endpoint you create, and there could be a lot of endpoints. Well, fear not. At the very least, you could create a factory class in a shared assembly to provide each endpoint with a preconfigured BusConfiguration
instance. In Chapter 7, Advanced Configuration, you will learn an even better way to manage this shared configuration, and in Chapter 9, Administration, you will learn how to manage the differences in it as we move from our development environment to production, and everywhere in between.
Now that we have a deeper understanding of how NServiceBus is hosted, in the next chapter, we will...