Security
Cloud App development Challenges
Data Mgmt. Design &
implementation
Availability
Management and
Monitoring
Messaging
Performance and
Scalability
Resiliency
Brokered Messaging
Azure Service Bus
• Brokered messaging communication model
• components of an application don’t communicate directly, but
rather exchange messages via an intermediary queue
• One-to-one, asynchronous, follows FIFO
Brokered Messaging
• Brokered messaging supports the scenario of truly temporal
decoupled systems where either message producer or
consumers availability is not guaranteed.
• the “broker” comes into play where the messages which are
not immediately delivered must live somewhere.
Relay Messaging
• Relay messaging provides the ability to “bounce” a message off
of a service to an connected receiver.
• It requires that the receiver expecting the message is online
and available.
Brokered Messaging
Queues
• Brokered messaging communication model
• components of an application don’t communicate directly, but
rather exchange messages via an intermediary queue
• One-to-one, asynchronous, follows FIFO
• Decoupled sender and receiver
• One or many senders.
• One or many (competing) receivers.
• Load leveling
• Temporal decoupling
• Load balancing
Sender Receiver
Sender
Receiver
Sender
Sender
Receiver
Brokered Messaging
Queues
Brokered Messaging
Topics
• pub/sub messaging communication model
• components of an application don’t communicate directly, but
rather exchange messages via an intermediary topic
• one-to-many, can register multiple subscriptions to a topic,
each message sent to a topic is available for each subscription
to handle independently
Topics & Subscriptions
• Senders send to a topic
• Receivers receive from
subscription
• Each subscription has one
copy of the message.
• Filters, Rules and Actions
Message distribution
Deliver the same message to more than one client. Subscribers can filter by interest.
Message partitioning
Receiver get mutually exclusive slices of the message stream.
Sender
Receiver
Sender
Sender Receiver
F1
F2
Receiver
TopicDescription mainTopic = namespaceManager.CreateTopic(“topicName");
namespaceManager.CreateSubscription(“topicName", “AuditSubscription");
namespaceManager.CreateSubscription(T“topicName", "FirstSubscription",
new SqlFilter("Address LIKE '%First%'"));
namespaceManager.CreateSubscription(T“topicName", “SecondSubscription",
new SqlFilter("Address LIKE '%Second%'"));
BrokeredMessage myMessage = new BrokeredMessage();
myMessage.Properties.Add(“Address”, “First”);
or
myMessage.Properties.Add(“Address”, “Second”);
or
myMessage.Properties.Add(“Address”, “First,Second”);
When two or more parties want to exchange information, they need a communication facilitator. Service Bus is a brokered, or third-party communication mechanism. This is similar to a postal service in the physical world. Postal services make it very easy to send different kinds of letters and packages with a variety of delivery guarantees, anywhere in the world.
Load leveling Receiver is never overloaded, process at its own pace.
Temporal decoupling Allows taking the receiver offline for servicing.
Load balancing Multiple receivers compete for messages.