The document summarizes the agenda and content of a MuleSoft meetup group meeting in Kolkata. The agenda included introductions, a presentation on integrating applications using Anypoint MQ, and best practices for secure properties in MuleSoft. The Anypoint MQ presentation covered topics like publish-subscribe integration patterns, using Anypoint MQ for publishing and subscribing to messages, acknowledgement modes, and comparisons to other message queues. It included a demo and a question and answer session. The meeting concluded with a trivia quiz, notices about sharing on social media, and requesting feedback.
4. 4
● About the Speaker:
A SHOW OF HANDS:
Who is new to this Meetup?
• 8+ Years experience in Integration
technologies and working as Solution
Architect at Apisero.
• MuleSoft meetup leader for Kolkata,
India
• Experience in other Integration
technologies like SoftwareAG
webMethods.
10. 10
Anypoint MQ
● Cloud native Message Queue Service
● Fully Integrated with Anypoint Platform
● Enables connection to non mule apps via REST apis
● Provides dead-letter queue capability for undeliverable messages.
● Supports large payloads, encryption, queuing, and publish/subscribe (pub/sub) paradigms.
● Underlying architecture is based on AWS SQS (Simple Queuing Service)
● Provides Anypoint Studio access, which makes the process of leveraging your queues and
message exchanges as simple as drag, drop, and configure.
11. 11
Anypoint MQ Publish
● Messages can be published to 2 types of Queues.
○ Standard Queue
These queues don’t guarantee a specific message order. Standard queues are the best fit for
applications in which messages must be delivered quickly.
Supports upto 120000 in-flight messages per standard queue.
Multiple standard queues can be bound to a message exchange.
○ FIFO Queue
These queues ensure that your messages arrive in order. FIFO queues are the best fit for applications
requiring strict message ordering and exactly-once delivery, but in which message delivery speed is of
less importance
It supports upto 10 messages per message group.
It doesn’t support message exchange.
12. 12
Anypoint MQ Subscribe
● Consume Operation
○ Consumes single message at any point in the flow
By default, the Consume operation waits for 10 seconds for a new message to arrive
when consuming from an empty queue. Consume fails if no message arrives in that
timeframe.
● Subscribe Operation
Listen for new messages as a subscriber source and consumes the incoming messages.
○ Maximum Throughput mode
○ Predictable Message Consumption Mode
13. 13
Message Acknowledgement
● Automatic
○ By default, the Subscriber source uses the AUTO acknowledgment mode.
○ It executes an ACK only when the processing finishes without exceptions
● Immediate
○ The consumed message is acknowledged right before being dispatched to the Mule flow. If
the message acknowledgment fails, the message is discarded.
● Manual
○ ackToken value is required for manual acknowledgement.
○ Ack: Acknowledging a message (ACK) informs the broker that the message has been processed
and must be removed from the queue to prevent redelivery.
○ Nack: Not acknowledging (NACK) a message informs the broker that the message was not
processed successfully and commands the broker to return the message to the queue for redelivery to
any available consumer.
15. 15
Standard and FIFO Queue Comparison
Criteria Standard Queue FIFO Queue
Message Concurrency Limited by mule runtime threading model maxConcurrency=1
Message Correlation Can be published with custom
MessageId/CorrelationId, but don’t have
subscription filtering
Can be published with custom
MessageId/CorrelationId, but don’t have
subscription filtering
Message ordering Not guaranteed (Best effort ordering) Guaranteed
Max payload size 10MB 10MB
TPS (Transaction Per Second) NA Default is 300 TPS. If batch size is 10 then it can
be raised upto 3000 tps.
Max in-flight message 120,000 10
Max batch size 10 (batchSize >10 is overridden) 10 (batchSize >10 is overridden)
Duplicate message NA Within deduplication interval duplicate messages
are discarded.
16. 16
Active MQ vs Anypoint MQ
Selection Criteria Active MQ Anypoint MQ
Deployment options Both on premise and cloud is available. Only available in cloud. AWS SQS is the backbone
Availability Based on installed location 3 regions
Data Size Depends on the disk size. Limits messages to 10MB.
Protocol support AMQP, MQTT, Stomp, OpenWire, REST and others Only works over HTTP. Uses HTTP long polling under the
hood.
Reconnection Strategy Supports. Doesn’t support as it doesn’t use a connection based
protocol.
Maximum TPS Not limited by design. Doesn’t have a limit for standard queues, but FIFO queues
can support maximum 3000 TPS.
Request/Reply message support Supports OOTB. Doesn’t support OOTB.
Guaranteed Message Capability Supports guaranteed delivery using persistence storage.
However persistence queue/topic performance is slower
than transient one.
Guarantees “at least once” delivery of messages
17. 17
Anypoint MQ FAQ
● In which regions Anypoint MQ is available?
○ US (NA, EU, APAC), EU(Frankfurt, Ireland) and APAC
● Can messages and queues shared between regions?
○ No
● What is the message size limit?
○ 10 MB
● Can Anypoint MQ be used on premise?
○ On premise deployment is not supported. However messages can be published from on premise app
to anypoint mq and can be subscribed by on premise app.
● Why do we receive fewer messages than the batch size while using AMQ conenctor?
○ Anypoint MQ works on the best effort mechanism as it’s based on SQS. For example, if there are 5
messages in a queue, the system returns anywhere from 0-5 messages in a single API call depending
on what distributed subsystems are accessed by that request.
● How to process messages from a DLQ?
○ Automatic processing of DLQ is not available at the moment. However a separate flow can be
implement to process DLQ messages.
19. 19
On your Cell Phone or Laptop go to KAHOOT.IT and enter the pin
that will be shared shortly
https://kahoot.com/
Questions and multi-choice answers will be displayed on this
screen. Use your Cell phone to select the right answer – You’ll
need both screens open to participate
Kahoot Quiz
21. 21
● Share:
○ Tweet using the hashtag #MuleSoftMeetups
○ Invite your network to join: https://meetups.mulesoft.com/adelaide/
● Feedback:
○ Fill out the survey feedback and suggest topics for upcoming events
○ Contact MuleSoft at meetups@mulesoft.com for ways to improve the program
What’s next?