#CommandBus.Lab
Simple Starter-Kit for an Azure Command Bus Lab.
##Get started
- Install Azure SDK > 2.2
- Create a Service Bus instance, and update the app.config files with the connection.
- Create Topic "commands" and subscription "nodeOneSub" through namespace manager or portal.
###Retry
"The Client-side Retry Policy feature enables you to set a retry policy on transient message delivery errors."
MessagingFactory factory = MessagingFactory.Create();
factory.RetryPolicy = RetryExponential.Default; // retry on transient errors until the OperationTimeout is reached
factory.RetryPolicy = RetryPolicy.NoRetry; // disables retry for tranisent errors
Source: Whats new i Azure SDK 2.1
#####2.2
var messagingFactory = MessagingFactory.Create();
_client = messagingFactory.CreateSubscriptionClient(topic, subscription);
_client.RetryPolicy = new RetryExponential(...);
###DeadLetter Brokered Messaging: Dead Letter Queue
###Transient Block
- The Transient Fault Handling Application Block
- Enterprise Library 5.0 - Transient Fault Handling Application Block 5.1.1212
- patterns & practices – Enterprise Library
###Sessions
MessageSession sessionReceiver =
subscriptionClient.AcceptMessageSession(TimeSpan.FromSeconds(5));
"Basically, what this means is that the client will check for any to-be-processed messages in the subscription—those whose SessionId property is not null—and if no such messages are encountered within a period of five seconds, the request will time out"
Windows Azure Service Bus: Messaging Patterns Using Sessions
###FIFO If ordering is of importance.
Message ordering on Windows Azure Service Bus Queues
###Partitions Partitioned Service Bus Queues and Topics