.net - One NServiceBus.Host for one EndPoint, what is the recommended approach -
i'm trying understand nservicebus given online documentation. can't wrap head around overall recommended setup of infrastructure. our app supposed able run both single machine , across multiple (logically different) sites (n stores-1 headquarter). nservicebus (i using v5 through nuget), don't understand notion of host , endpoints.
lets have 15 services (order service, item service, etc.).
do need 15 clients (15 class library projects code sending messages on bus), , 15 servers (one or more receiving messages handler classes handle service specific messages/commands)? 30 total.
should each service utilize own separate msmq?
for 15 "server" projects, in production environment need install nservicebus.host 15 times (hence creating 15 windows service instances). during debugging in vs, nserivcebus.host.exe started when start debugging.
so "host" 1 endpoint each host/server project. or can have single host , 15 endpoints within of it?
you can tell new esb pattern, input.
you don't need 15 class libraries. nservicebus can router messages based on namespace/type. eg: namespace messages of "message.orders" can routed "orders" queue.
in production possibility.. depends on volume of messages , logical grouping/partitioning. in development, have 1 queue messages.
again, deployment issue dictated logical partitioning. have scripted handle installation/un-installation of these services. have mine in powershell script.
nservicebus flexible on how , when partition messages. done @ configuration level in uat or production , outside development lifecycle. maintain in mind, 1 nservicebus host == 1 msmq
i started 1 service first, start partitioning based on volume/priority messages.
also, reason breakdown messages 15 classes, if want expose these assemblies external solutions without exposing other message types.
.net msmq nservicebus esb nservicebus4
No comments:
Post a Comment