MSA

You can download an example of the solution here

How use

Create bus from string

Command example

Handler example

appsettings.json

service.json


The above config describes handler and one repeated operation.

  • subscriptionEndpoint = queue name that the handler subscribes to
  • useExchange - if this parameter is set, Exchange is created with the full name of the type
  • degreeOfParallelism - how many handler instances will be run
  • retry - if an error occurs, the message is thrown to the end of the queue
  • routingKey - additional parameter
  • prefetchCount - utilize prefetch count for consumer
  • retryCount - how many time try to retry, if not set is infinite
  • type - the type of handler that must be registered in Container
  • name - just alias, to create logical units, you can't have 2 identical names in the same service
  • service is logical unit can be as many as you want
  • you can also pass other additional parameters to the handler and get them from ISettings

  • command is another type of handler, a recurring operation that has the following parameters


  • period this is the service execution period
  • isConcurrentMode can I start a new thread if the old operation has not completed yet