SlideShare a Scribd company logo
Apache ActiveMQ Enterprise Messaging in Action
About me Bosanac Dejan Senior Software Engineer at FUSESource -  http://fusesource.com Apache ActiveMQ commiter Co-author of ActiveMQ in Action
The Basics
Messaging is Loosely coupled exchange of messages between applications Location transparency Can be persistent or non-persistent Can be transactional
Topics
Topics One message goes to 0-to-many consumers based on the current subscribers Think like mailing lists or discussion forums Ideal for publishing business events  Distributed observer pattern Allows one part of your system to notify anyone else who may be interested in an event
Queues
Queues Messages are load balanced across many consumers Each message goes to exactly one consumer Consumers compete for messages  Its easy to browse and monitor queues Ideal for grid style applications
What is ActiveMQ?
Apache ActiveMQ Apache ActiveMQ Leading Open Source messaging platform Supported Java Standards: JMS 1.1, J2EE 1.4, JCA 1.5 and XA Reliable, high performance messaging Out-performs many legacy proprietary message queues Configurable for many different deployments Multi-Protocol/Multi-Language Support
Background ActiveMQ started in 2005 at CodeHaus Moved to Apache Software Foundation in 2006 914,898 lines of code 24 committers Now the most widely used open source messaging system on the planet
Enterprise Features
Enterprise Features Failover High Availability Clustering Wide area deployment Management Security
Client Failover Java and C++ clients support seamless failover
High Availability Pure Master/Slave JDBC Master/Slave Shared File System Master/Slave
Pure Master/Slave Shared nothing Fully replicated All messages All acknowledgements All transactions Slave does not start any transports or network connections
Pure Master/Slave
Pure Master/Slave On Master Failure: Slave will shutdown Or Slave will start all network and transports – becoming the master
JDBC Master/Slave
JDBC Master/Slave Extreme reliability – but not as fast Recommended if already using an enterprise database No restriction on number of slaves Simple configuration
Shared Storage Master/Slave
Shared Storage Master/Slave Recommended if you have a SAN No restriction on number of slaves Simple configuration N.B. – ensure file locking works – and times out – NFSv4 good!
Security Secure channels (SSL) Authentication File based JAAS plugin (Certificates, LDAP) Authorization Destination Level Message Level
Monitoring Java JConsole – via JMX FuseHQ – via JMX ActiveMQ Web Console Advisory messages Statistics plug-in (agnostic)
Performance Tuning
Tuning Producers Persistent vs Non-persistent Messages Transactions Embedding Brokers
Persistent Messages
Non-Persistent Messages Non-persistent delivery is signaficantly faster Message Producer sends message to the Broker asynchronously Message is held in temporary storage 20x improvement in performance
Non-Persistent Reliability Non-persistent may be reliable enough Messages are cached for resending on the Producer Broker can filter out duplicates  Consumer can filter out duplicates
Transactions Use Transactions for Persistent Messages Only the transaction boundary (commit) is synchronous Messages are batched to storage Messages cached in broker until a Transaction boundary Benefits of persistence – performance of non-persistence
Embedded Brokers
Tuning Consumers Concurrent Consumers Prefetch Limit Acknowledgment modes Asynchronous delivery
Concurrent Consumers Processing messages concurrently – improve performance Message order will be affected however Can achieve concurrency by: Multiple Sessions and Consumers Use JMS ConnectionConsumer Use a container – e.g. Spring  MessageDrivenBeans
Prefetch Limit
Acknowledgment modes Different Acknowledgement Modes: Session.AUTO_ACKNOWLEDGE optimizeAcknowledge Session.CLIENT_ACKNOWLEDGE Session.SESSION_TRANSACTED Session.DUPS_OK ActiveMQSession.INDIVIDUAL_ACKNOWLEDGE
Asynchronous Dispatch
Scaling
Vertical Scaling Vertical Scaling: Increase load capacity using a single broker can handle. Enable optimzeDispatch Disable UseDedicatedTaskRunner Disable tight encoding in wire format Increase memory allocation to the broker Try using the NIO transport Upgrade the hardware Cons There is a limit to the scalability a single machine can give
Horizontal Scaling Horizontal Scaling: Increase load capacity using many brokers Implemented using a Network of Brokers Messages a forwarded between brokers to interested consumers. Lifts the limit of using a single machine to scale. Cons Advisory messages must be abled to support demand based forwarding. Delivery failure between brokers will result in re-delivery and a possible duplicate message. Complex network topologies can lead to non-optimal message routing.
Hybrid Scaling Hybrid of Vertical and Horizontal Scaling Multiple broker nodes are used by the clients Brokers are NOT networked The client application send message to different brokers, typically based on some defined partitioning of the data. Pros You can use all the tuning techniques used in Vertical scaling Have better Horizontal scaleability than using Network Of Brokers (Less broker cross talk) Cons Added complexity required on the end user Application
Beyond Java
Stomp Designed and implemented by ActiveMQ team Designed to be easy to use and implement Lots of client implementations: Ruby,C, Dynamic C, C++, C#, .Net, Delphi, Flash, hx, Perl, PHP, Pike, Python, Smalltalk – to name a few.
OpenWire clients Efficient binary implementation Network outage detection Client failover Java, C++ and C# clients.
Web REST Ajax WebSockets
Apache Camel XMPP Gateway FTP Sockets Mail Esper Atom Cometd Many, many more
Delivery Scheduling Modes Timer Cron Hybrid Example Usage Distribute repeated jobs Replace Cron, Java Timer or Quartz message.setStringProperty(ScheduledMessage.AMQ_SCHEDULED_CRON, "30 * * * *");   message.setLongProperty(ScheduledMessage.AMQ_SCHEDULED_DELAY, 10*1000);   message.setLongProperty(ScheduledMessage.AMQ_SCHEDULED_PERIOD, 10*1000);   message.setIntProperty(ScheduledMessage.AMQ_SCHEDULED_REPEAT, 9);
Future (ActiveMQ 6.0) New Java/Scala Core - fast, scalable, modular Modular design - OSGi friendly, Hot Deployment, Dynamic Configuration New Stores (Apache Cassandra - replicated datacenter store) New Protocols (AMQP 1.0, Beanstalkd, Stomp 1.1 and 2.0) Better Web (RestMQ, WebHooks, WebSockets)
Conclusions Dynamic community Leading in terms of messaging innovation Built for Enterprise Scalable, Good Performance, Reliable
Questions? ActiveMQ Web sites:  http ://activemq.apache.org / http ://fusesource.com/products/enterprise-activemq / Blog:  http://www.nighttale.net / Twitter:  http ://twitter.com /dejanb http://twitter.com/fusenews

More Related Content

What's hot

Do we need JMS in 21st century?
Do we need JMS in 21st century?Do we need JMS in 21st century?
Do we need JMS in 21st century?
Mikalai Alimenkou
 
ActiveMQ In Action
ActiveMQ In ActionActiveMQ In Action
ActiveMQ In Action
Bruce Snyder
 
Introduction to NServiceBus
Introduction to NServiceBusIntroduction to NServiceBus
Introduction to NServiceBus
Adam Fyles
 
Connecting Applications Everywhere with ActiveMQ
Connecting Applications Everywhere with ActiveMQConnecting Applications Everywhere with ActiveMQ
Connecting Applications Everywhere with ActiveMQ
Rob Davies
 
Jms deep dive [con4864]
Jms deep dive [con4864]Jms deep dive [con4864]
Jms deep dive [con4864]
Ryan Cuprak
 
JMS and ActiveMQ - VuNV 201307
JMS and ActiveMQ - VuNV 201307JMS and ActiveMQ - VuNV 201307
JMS and ActiveMQ - VuNV 201307
Framgia Vietnam
 
NServiceBus - introduction to a message based distributed architecture
NServiceBus - introduction to a message based distributed architectureNServiceBus - introduction to a message based distributed architecture
NServiceBus - introduction to a message based distributed architecture
Mauro Servienti
 
ActiveMQ In Action - ApacheCon 2011
ActiveMQ In Action - ApacheCon 2011ActiveMQ In Action - ApacheCon 2011
ActiveMQ In Action - ApacheCon 2011
Bruce Snyder
 
IBM MQ vs Apache ActiveMQ
IBM MQ vs Apache ActiveMQIBM MQ vs Apache ActiveMQ
IBM MQ vs Apache ActiveMQ
Roman Kharkovski
 
Understanding JMS Integration Patterns
Understanding JMS Integration Patterns Understanding JMS Integration Patterns
Understanding JMS Integration Patterns
WSO2
 
Rabbitmq an amqp message broker
Rabbitmq an amqp message brokerRabbitmq an amqp message broker
Rabbitmq an amqp message broker
ANASYS
 
Making communications across boundaries simple with NServiceBus
Making communications across boundaries simple with NServiceBusMaking communications across boundaries simple with NServiceBus
Making communications across boundaries simple with NServiceBus
Particular Software
 
RabbitMq
RabbitMqRabbitMq
RabbitMq
Ahmad Saif
 
AMQP 1.0 introduction
AMQP 1.0 introductionAMQP 1.0 introduction
AMQP 1.0 introduction
Clemens Vasters
 
Implementing WebServices with Camel and CXF in ServiceMix
Implementing WebServices with Camel and CXF in ServiceMixImplementing WebServices with Camel and CXF in ServiceMix
Implementing WebServices with Camel and CXF in ServiceMix
Adrian Trenaman
 
Making communication across boundaries simple with Azure Service Bus
Making communication across boundaries simple with Azure Service BusMaking communication across boundaries simple with Azure Service Bus
Making communication across boundaries simple with Azure Service Bus
Particular Software
 
Mini-Training: Message Brokers
Mini-Training: Message BrokersMini-Training: Message Brokers
Mini-Training: Message Brokers
Betclic Everest Group Tech Team
 
The Art of Message Queues - TEKX
The Art of Message Queues - TEKXThe Art of Message Queues - TEKX
The Art of Message Queues - TEKX
Mike Willbanks
 
XMPP Academy #1
XMPP Academy #1XMPP Academy #1
XMPP Academy #1
Mickaël Rémond
 
Art Of Message Queues
Art Of Message QueuesArt Of Message Queues
Art Of Message Queues
Mike Willbanks
 

What's hot (20)

Do we need JMS in 21st century?
Do we need JMS in 21st century?Do we need JMS in 21st century?
Do we need JMS in 21st century?
 
ActiveMQ In Action
ActiveMQ In ActionActiveMQ In Action
ActiveMQ In Action
 
Introduction to NServiceBus
Introduction to NServiceBusIntroduction to NServiceBus
Introduction to NServiceBus
 
Connecting Applications Everywhere with ActiveMQ
Connecting Applications Everywhere with ActiveMQConnecting Applications Everywhere with ActiveMQ
Connecting Applications Everywhere with ActiveMQ
 
Jms deep dive [con4864]
Jms deep dive [con4864]Jms deep dive [con4864]
Jms deep dive [con4864]
 
JMS and ActiveMQ - VuNV 201307
JMS and ActiveMQ - VuNV 201307JMS and ActiveMQ - VuNV 201307
JMS and ActiveMQ - VuNV 201307
 
NServiceBus - introduction to a message based distributed architecture
NServiceBus - introduction to a message based distributed architectureNServiceBus - introduction to a message based distributed architecture
NServiceBus - introduction to a message based distributed architecture
 
ActiveMQ In Action - ApacheCon 2011
ActiveMQ In Action - ApacheCon 2011ActiveMQ In Action - ApacheCon 2011
ActiveMQ In Action - ApacheCon 2011
 
IBM MQ vs Apache ActiveMQ
IBM MQ vs Apache ActiveMQIBM MQ vs Apache ActiveMQ
IBM MQ vs Apache ActiveMQ
 
Understanding JMS Integration Patterns
Understanding JMS Integration Patterns Understanding JMS Integration Patterns
Understanding JMS Integration Patterns
 
Rabbitmq an amqp message broker
Rabbitmq an amqp message brokerRabbitmq an amqp message broker
Rabbitmq an amqp message broker
 
Making communications across boundaries simple with NServiceBus
Making communications across boundaries simple with NServiceBusMaking communications across boundaries simple with NServiceBus
Making communications across boundaries simple with NServiceBus
 
RabbitMq
RabbitMqRabbitMq
RabbitMq
 
AMQP 1.0 introduction
AMQP 1.0 introductionAMQP 1.0 introduction
AMQP 1.0 introduction
 
Implementing WebServices with Camel and CXF in ServiceMix
Implementing WebServices with Camel and CXF in ServiceMixImplementing WebServices with Camel and CXF in ServiceMix
Implementing WebServices with Camel and CXF in ServiceMix
 
Making communication across boundaries simple with Azure Service Bus
Making communication across boundaries simple with Azure Service BusMaking communication across boundaries simple with Azure Service Bus
Making communication across boundaries simple with Azure Service Bus
 
Mini-Training: Message Brokers
Mini-Training: Message BrokersMini-Training: Message Brokers
Mini-Training: Message Brokers
 
The Art of Message Queues - TEKX
The Art of Message Queues - TEKXThe Art of Message Queues - TEKX
The Art of Message Queues - TEKX
 
XMPP Academy #1
XMPP Academy #1XMPP Academy #1
XMPP Academy #1
 
Art Of Message Queues
Art Of Message QueuesArt Of Message Queues
Art Of Message Queues
 

Similar to Apache ActiveMQ - Enterprise messaging in action

Apache kafka
Apache kafkaApache kafka
Apache kafka
Srikrishna k
 
ActiveMQ interview Questions and Answers
ActiveMQ interview Questions and AnswersActiveMQ interview Questions and Answers
ActiveMQ interview Questions and Answers
jeetendra mandal
 
January 2011 HUG: Kafka Presentation
January 2011 HUG: Kafka PresentationJanuary 2011 HUG: Kafka Presentation
January 2011 HUG: Kafka Presentation
Yahoo Developer Network
 
AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...
AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...
AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...
GeeksLab Odessa
 
Messaging - RabbitMQ, Azure (Service Bus), Docker and Azure Functions
Messaging - RabbitMQ, Azure (Service Bus), Docker and Azure FunctionsMessaging - RabbitMQ, Azure (Service Bus), Docker and Azure Functions
Messaging - RabbitMQ, Azure (Service Bus), Docker and Azure Functions
John Staveley
 
Chapter16 new
Chapter16 newChapter16 new
Chapter16 new
vmummaneni
 
Hpe service virtualization 3.8 what's new chicago adm
Hpe service virtualization 3.8 what's new chicago admHpe service virtualization 3.8 what's new chicago adm
Hpe service virtualization 3.8 what's new chicago adm
Jeffrey Nunn
 
Apache kafka
Apache kafkaApache kafka
Apache kafka
Ramakrishna kapa
 
MNPHP Scalable Architecture 101 - Feb 3 2011
MNPHP Scalable Architecture 101 - Feb 3 2011MNPHP Scalable Architecture 101 - Feb 3 2011
MNPHP Scalable Architecture 101 - Feb 3 2011
Mike Willbanks
 
Message Broker implementation in Kubernetes
Message Broker implementation in KubernetesMessage Broker implementation in Kubernetes
Message Broker implementation in Kubernetes
Suman Chakraborty
 
Scenic City Summit (2021): Real-Time Streaming in any and all clouds, hybrid...
Scenic City Summit (2021):  Real-Time Streaming in any and all clouds, hybrid...Scenic City Summit (2021):  Real-Time Streaming in any and all clouds, hybrid...
Scenic City Summit (2021): Real-Time Streaming in any and all clouds, hybrid...
Timothy Spann
 
High volume real time contiguous etl and audit
High volume real time contiguous etl and auditHigh volume real time contiguous etl and audit
High volume real time contiguous etl and audit
Remus Rusanu
 
Big Data Streams Architectures. Why? What? How?
Big Data Streams Architectures. Why? What? How?Big Data Streams Architectures. Why? What? How?
Big Data Streams Architectures. Why? What? How?
Anton Nazaruk
 
Usemon; Building The Big Brother Of The Java Virtual Machinve
Usemon; Building The Big Brother Of The Java Virtual MachinveUsemon; Building The Big Brother Of The Java Virtual Machinve
Usemon; Building The Big Brother Of The Java Virtual Machinve
Paul René Jørgensen
 
Continuent Tungsten - Scalable Saa S Data Management
Continuent Tungsten - Scalable Saa S Data ManagementContinuent Tungsten - Scalable Saa S Data Management
Continuent Tungsten - Scalable Saa S Data Management
guest2e11e8
 
Introduction To Cloud Computing
Introduction To Cloud ComputingIntroduction To Cloud Computing
Introduction To Cloud Computing
Rinat Shagisultanov
 
Microsoft Azure Cloud Basics Tutorial
Microsoft Azure Cloud Basics TutorialMicrosoft Azure Cloud Basics Tutorial
Microsoft Azure Cloud Basics Tutorial
IIMSE Edu
 
Aceu2009 Apache Synapse Events
Aceu2009 Apache Synapse EventsAceu2009 Apache Synapse Events
Aceu2009 Apache Synapse Events
guest60ed0b
 
Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...
Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...
Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...
Videoguy
 
Messaging in Java
Messaging in JavaMessaging in Java
Messaging in Java
Dmitry Buzdin
 

Similar to Apache ActiveMQ - Enterprise messaging in action (20)

Apache kafka
Apache kafkaApache kafka
Apache kafka
 
ActiveMQ interview Questions and Answers
ActiveMQ interview Questions and AnswersActiveMQ interview Questions and Answers
ActiveMQ interview Questions and Answers
 
January 2011 HUG: Kafka Presentation
January 2011 HUG: Kafka PresentationJanuary 2011 HUG: Kafka Presentation
January 2011 HUG: Kafka Presentation
 
AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...
AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...
AI&BigData Lab 2016. Сарапин Виктор: Размер имеет значение: анализ по требова...
 
Messaging - RabbitMQ, Azure (Service Bus), Docker and Azure Functions
Messaging - RabbitMQ, Azure (Service Bus), Docker and Azure FunctionsMessaging - RabbitMQ, Azure (Service Bus), Docker and Azure Functions
Messaging - RabbitMQ, Azure (Service Bus), Docker and Azure Functions
 
Chapter16 new
Chapter16 newChapter16 new
Chapter16 new
 
Hpe service virtualization 3.8 what's new chicago adm
Hpe service virtualization 3.8 what's new chicago admHpe service virtualization 3.8 what's new chicago adm
Hpe service virtualization 3.8 what's new chicago adm
 
Apache kafka
Apache kafkaApache kafka
Apache kafka
 
MNPHP Scalable Architecture 101 - Feb 3 2011
MNPHP Scalable Architecture 101 - Feb 3 2011MNPHP Scalable Architecture 101 - Feb 3 2011
MNPHP Scalable Architecture 101 - Feb 3 2011
 
Message Broker implementation in Kubernetes
Message Broker implementation in KubernetesMessage Broker implementation in Kubernetes
Message Broker implementation in Kubernetes
 
Scenic City Summit (2021): Real-Time Streaming in any and all clouds, hybrid...
Scenic City Summit (2021):  Real-Time Streaming in any and all clouds, hybrid...Scenic City Summit (2021):  Real-Time Streaming in any and all clouds, hybrid...
Scenic City Summit (2021): Real-Time Streaming in any and all clouds, hybrid...
 
High volume real time contiguous etl and audit
High volume real time contiguous etl and auditHigh volume real time contiguous etl and audit
High volume real time contiguous etl and audit
 
Big Data Streams Architectures. Why? What? How?
Big Data Streams Architectures. Why? What? How?Big Data Streams Architectures. Why? What? How?
Big Data Streams Architectures. Why? What? How?
 
Usemon; Building The Big Brother Of The Java Virtual Machinve
Usemon; Building The Big Brother Of The Java Virtual MachinveUsemon; Building The Big Brother Of The Java Virtual Machinve
Usemon; Building The Big Brother Of The Java Virtual Machinve
 
Continuent Tungsten - Scalable Saa S Data Management
Continuent Tungsten - Scalable Saa S Data ManagementContinuent Tungsten - Scalable Saa S Data Management
Continuent Tungsten - Scalable Saa S Data Management
 
Introduction To Cloud Computing
Introduction To Cloud ComputingIntroduction To Cloud Computing
Introduction To Cloud Computing
 
Microsoft Azure Cloud Basics Tutorial
Microsoft Azure Cloud Basics TutorialMicrosoft Azure Cloud Basics Tutorial
Microsoft Azure Cloud Basics Tutorial
 
Aceu2009 Apache Synapse Events
Aceu2009 Apache Synapse EventsAceu2009 Apache Synapse Events
Aceu2009 Apache Synapse Events
 
Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...
Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...
Remarks on Grids e-Science CyberInfrastructure and Peer-to-Peer ...
 
Messaging in Java
Messaging in JavaMessaging in Java
Messaging in Java
 

More from dejanb

How is this sausage made
How is this sausage madeHow is this sausage made
How is this sausage made
dejanb
 
Messaging for the cloud
Messaging for the cloudMessaging for the cloud
Messaging for the cloud
dejanb
 
Scaling out eclipse hono
Scaling out eclipse honoScaling out eclipse hono
Scaling out eclipse hono
dejanb
 
Building Open Source IoT Cloud
Building Open Source IoT CloudBuilding Open Source IoT Cloud
Building Open Source IoT Cloud
dejanb
 
Messaging for IoT
Messaging for IoTMessaging for IoT
Messaging for IoT
dejanb
 
Messaging for Web and Mobile with Apache ActiveMQ
Messaging for Web and Mobile with Apache ActiveMQMessaging for Web and Mobile with Apache ActiveMQ
Messaging for Web and Mobile with Apache ActiveMQ
dejanb
 
Introduction to ActiveMQ Apollo
Introduction to ActiveMQ ApolloIntroduction to ActiveMQ Apollo
Introduction to ActiveMQ Apollo
dejanb
 
Deploying FuseMQ with Fuse Fabric
Deploying FuseMQ with Fuse FabricDeploying FuseMQ with Fuse Fabric
Deploying FuseMQ with Fuse Fabric
dejanb
 
Advanced messaging with Apache ActiveMQ
Advanced messaging with Apache ActiveMQAdvanced messaging with Apache ActiveMQ
Advanced messaging with Apache ActiveMQ
dejanb
 

More from dejanb (9)

How is this sausage made
How is this sausage madeHow is this sausage made
How is this sausage made
 
Messaging for the cloud
Messaging for the cloudMessaging for the cloud
Messaging for the cloud
 
Scaling out eclipse hono
Scaling out eclipse honoScaling out eclipse hono
Scaling out eclipse hono
 
Building Open Source IoT Cloud
Building Open Source IoT CloudBuilding Open Source IoT Cloud
Building Open Source IoT Cloud
 
Messaging for IoT
Messaging for IoTMessaging for IoT
Messaging for IoT
 
Messaging for Web and Mobile with Apache ActiveMQ
Messaging for Web and Mobile with Apache ActiveMQMessaging for Web and Mobile with Apache ActiveMQ
Messaging for Web and Mobile with Apache ActiveMQ
 
Introduction to ActiveMQ Apollo
Introduction to ActiveMQ ApolloIntroduction to ActiveMQ Apollo
Introduction to ActiveMQ Apollo
 
Deploying FuseMQ with Fuse Fabric
Deploying FuseMQ with Fuse FabricDeploying FuseMQ with Fuse Fabric
Deploying FuseMQ with Fuse Fabric
 
Advanced messaging with Apache ActiveMQ
Advanced messaging with Apache ActiveMQAdvanced messaging with Apache ActiveMQ
Advanced messaging with Apache ActiveMQ
 

Recently uploaded

Best Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdfBest Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdf
Tatiana Al-Chueyr
 
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdfINDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
jackson110191
 
Research Directions for Cross Reality Interfaces
Research Directions for Cross Reality InterfacesResearch Directions for Cross Reality Interfaces
Research Directions for Cross Reality Interfaces
Mark Billinghurst
 
The Increasing Use of the National Research Platform by the CSU Campuses
The Increasing Use of the National Research Platform by the CSU CampusesThe Increasing Use of the National Research Platform by the CSU Campuses
The Increasing Use of the National Research Platform by the CSU Campuses
Larry Smarr
 
Password Rotation in 2024 is still Relevant
Password Rotation in 2024 is still RelevantPassword Rotation in 2024 is still Relevant
Password Rotation in 2024 is still Relevant
Bert Blevins
 
TrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-In
TrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-InTrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-In
TrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-In
TrustArc
 
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdfBT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
Neo4j
 
What’s New in Teams Calling, Meetings and Devices May 2024
What’s New in Teams Calling, Meetings and Devices May 2024What’s New in Teams Calling, Meetings and Devices May 2024
What’s New in Teams Calling, Meetings and Devices May 2024
Stephanie Beckett
 
Best Programming Language for Civil Engineers
Best Programming Language for Civil EngineersBest Programming Language for Civil Engineers
Best Programming Language for Civil Engineers
Awais Yaseen
 
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdfWhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
ArgaBisma
 
Transcript: Details of description part II: Describing images in practice - T...
Transcript: Details of description part II: Describing images in practice - T...Transcript: Details of description part II: Describing images in practice - T...
Transcript: Details of description part II: Describing images in practice - T...
BookNet Canada
 
What's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptxWhat's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptx
Stephanie Beckett
 
20240705 QFM024 Irresponsible AI Reading List June 2024
20240705 QFM024 Irresponsible AI Reading List June 202420240705 QFM024 Irresponsible AI Reading List June 2024
20240705 QFM024 Irresponsible AI Reading List June 2024
Matthew Sinclair
 
20240702 Présentation Plateforme GenAI.pdf
20240702 Présentation Plateforme GenAI.pdf20240702 Présentation Plateforme GenAI.pdf
20240702 Présentation Plateforme GenAI.pdf
Sally Laouacheria
 
Manual | Product | Research Presentation
Manual | Product | Research PresentationManual | Product | Research Presentation
Manual | Product | Research Presentation
welrejdoall
 
Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...
Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...
Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...
Bert Blevins
 
Choose our Linux Web Hosting for a seamless and successful online presence
Choose our Linux Web Hosting for a seamless and successful online presenceChoose our Linux Web Hosting for a seamless and successful online presence
Choose our Linux Web Hosting for a seamless and successful online presence
rajancomputerfbd
 
Observability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetryObservability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetry
Eric D. Schabell
 
How Social Media Hackers Help You to See Your Wife's Message.pdf
How Social Media Hackers Help You to See Your Wife's Message.pdfHow Social Media Hackers Help You to See Your Wife's Message.pdf
How Social Media Hackers Help You to See Your Wife's Message.pdf
HackersList
 
Coordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar SlidesCoordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar Slides
Safe Software
 

Recently uploaded (20)

Best Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdfBest Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdf
 
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdfINDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
 
Research Directions for Cross Reality Interfaces
Research Directions for Cross Reality InterfacesResearch Directions for Cross Reality Interfaces
Research Directions for Cross Reality Interfaces
 
The Increasing Use of the National Research Platform by the CSU Campuses
The Increasing Use of the National Research Platform by the CSU CampusesThe Increasing Use of the National Research Platform by the CSU Campuses
The Increasing Use of the National Research Platform by the CSU Campuses
 
Password Rotation in 2024 is still Relevant
Password Rotation in 2024 is still RelevantPassword Rotation in 2024 is still Relevant
Password Rotation in 2024 is still Relevant
 
TrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-In
TrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-InTrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-In
TrustArc Webinar - 2024 Data Privacy Trends: A Mid-Year Check-In
 
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdfBT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
 
What’s New in Teams Calling, Meetings and Devices May 2024
What’s New in Teams Calling, Meetings and Devices May 2024What’s New in Teams Calling, Meetings and Devices May 2024
What’s New in Teams Calling, Meetings and Devices May 2024
 
Best Programming Language for Civil Engineers
Best Programming Language for Civil EngineersBest Programming Language for Civil Engineers
Best Programming Language for Civil Engineers
 
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdfWhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
 
Transcript: Details of description part II: Describing images in practice - T...
Transcript: Details of description part II: Describing images in practice - T...Transcript: Details of description part II: Describing images in practice - T...
Transcript: Details of description part II: Describing images in practice - T...
 
What's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptxWhat's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptx
 
20240705 QFM024 Irresponsible AI Reading List June 2024
20240705 QFM024 Irresponsible AI Reading List June 202420240705 QFM024 Irresponsible AI Reading List June 2024
20240705 QFM024 Irresponsible AI Reading List June 2024
 
20240702 Présentation Plateforme GenAI.pdf
20240702 Présentation Plateforme GenAI.pdf20240702 Présentation Plateforme GenAI.pdf
20240702 Présentation Plateforme GenAI.pdf
 
Manual | Product | Research Presentation
Manual | Product | Research PresentationManual | Product | Research Presentation
Manual | Product | Research Presentation
 
Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...
Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...
Understanding Insider Security Threats: Types, Examples, Effects, and Mitigat...
 
Choose our Linux Web Hosting for a seamless and successful online presence
Choose our Linux Web Hosting for a seamless and successful online presenceChoose our Linux Web Hosting for a seamless and successful online presence
Choose our Linux Web Hosting for a seamless and successful online presence
 
Observability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetryObservability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetry
 
How Social Media Hackers Help You to See Your Wife's Message.pdf
How Social Media Hackers Help You to See Your Wife's Message.pdfHow Social Media Hackers Help You to See Your Wife's Message.pdf
How Social Media Hackers Help You to See Your Wife's Message.pdf
 
Coordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar SlidesCoordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar Slides
 

Apache ActiveMQ - Enterprise messaging in action

  • 1. Apache ActiveMQ Enterprise Messaging in Action
  • 2. About me Bosanac Dejan Senior Software Engineer at FUSESource - http://fusesource.com Apache ActiveMQ commiter Co-author of ActiveMQ in Action
  • 4. Messaging is Loosely coupled exchange of messages between applications Location transparency Can be persistent or non-persistent Can be transactional
  • 6. Topics One message goes to 0-to-many consumers based on the current subscribers Think like mailing lists or discussion forums Ideal for publishing business events Distributed observer pattern Allows one part of your system to notify anyone else who may be interested in an event
  • 8. Queues Messages are load balanced across many consumers Each message goes to exactly one consumer Consumers compete for messages Its easy to browse and monitor queues Ideal for grid style applications
  • 10. Apache ActiveMQ Apache ActiveMQ Leading Open Source messaging platform Supported Java Standards: JMS 1.1, J2EE 1.4, JCA 1.5 and XA Reliable, high performance messaging Out-performs many legacy proprietary message queues Configurable for many different deployments Multi-Protocol/Multi-Language Support
  • 11. Background ActiveMQ started in 2005 at CodeHaus Moved to Apache Software Foundation in 2006 914,898 lines of code 24 committers Now the most widely used open source messaging system on the planet
  • 13. Enterprise Features Failover High Availability Clustering Wide area deployment Management Security
  • 14. Client Failover Java and C++ clients support seamless failover
  • 15. High Availability Pure Master/Slave JDBC Master/Slave Shared File System Master/Slave
  • 16. Pure Master/Slave Shared nothing Fully replicated All messages All acknowledgements All transactions Slave does not start any transports or network connections
  • 18. Pure Master/Slave On Master Failure: Slave will shutdown Or Slave will start all network and transports – becoming the master
  • 20. JDBC Master/Slave Extreme reliability – but not as fast Recommended if already using an enterprise database No restriction on number of slaves Simple configuration
  • 22. Shared Storage Master/Slave Recommended if you have a SAN No restriction on number of slaves Simple configuration N.B. – ensure file locking works – and times out – NFSv4 good!
  • 23. Security Secure channels (SSL) Authentication File based JAAS plugin (Certificates, LDAP) Authorization Destination Level Message Level
  • 24. Monitoring Java JConsole – via JMX FuseHQ – via JMX ActiveMQ Web Console Advisory messages Statistics plug-in (agnostic)
  • 26. Tuning Producers Persistent vs Non-persistent Messages Transactions Embedding Brokers
  • 28. Non-Persistent Messages Non-persistent delivery is signaficantly faster Message Producer sends message to the Broker asynchronously Message is held in temporary storage 20x improvement in performance
  • 29. Non-Persistent Reliability Non-persistent may be reliable enough Messages are cached for resending on the Producer Broker can filter out duplicates Consumer can filter out duplicates
  • 30. Transactions Use Transactions for Persistent Messages Only the transaction boundary (commit) is synchronous Messages are batched to storage Messages cached in broker until a Transaction boundary Benefits of persistence – performance of non-persistence
  • 32. Tuning Consumers Concurrent Consumers Prefetch Limit Acknowledgment modes Asynchronous delivery
  • 33. Concurrent Consumers Processing messages concurrently – improve performance Message order will be affected however Can achieve concurrency by: Multiple Sessions and Consumers Use JMS ConnectionConsumer Use a container – e.g. Spring MessageDrivenBeans
  • 35. Acknowledgment modes Different Acknowledgement Modes: Session.AUTO_ACKNOWLEDGE optimizeAcknowledge Session.CLIENT_ACKNOWLEDGE Session.SESSION_TRANSACTED Session.DUPS_OK ActiveMQSession.INDIVIDUAL_ACKNOWLEDGE
  • 38. Vertical Scaling Vertical Scaling: Increase load capacity using a single broker can handle. Enable optimzeDispatch Disable UseDedicatedTaskRunner Disable tight encoding in wire format Increase memory allocation to the broker Try using the NIO transport Upgrade the hardware Cons There is a limit to the scalability a single machine can give
  • 39. Horizontal Scaling Horizontal Scaling: Increase load capacity using many brokers Implemented using a Network of Brokers Messages a forwarded between brokers to interested consumers. Lifts the limit of using a single machine to scale. Cons Advisory messages must be abled to support demand based forwarding. Delivery failure between brokers will result in re-delivery and a possible duplicate message. Complex network topologies can lead to non-optimal message routing.
  • 40. Hybrid Scaling Hybrid of Vertical and Horizontal Scaling Multiple broker nodes are used by the clients Brokers are NOT networked The client application send message to different brokers, typically based on some defined partitioning of the data. Pros You can use all the tuning techniques used in Vertical scaling Have better Horizontal scaleability than using Network Of Brokers (Less broker cross talk) Cons Added complexity required on the end user Application
  • 42. Stomp Designed and implemented by ActiveMQ team Designed to be easy to use and implement Lots of client implementations: Ruby,C, Dynamic C, C++, C#, .Net, Delphi, Flash, hx, Perl, PHP, Pike, Python, Smalltalk – to name a few.
  • 43. OpenWire clients Efficient binary implementation Network outage detection Client failover Java, C++ and C# clients.
  • 44. Web REST Ajax WebSockets
  • 45. Apache Camel XMPP Gateway FTP Sockets Mail Esper Atom Cometd Many, many more
  • 46. Delivery Scheduling Modes Timer Cron Hybrid Example Usage Distribute repeated jobs Replace Cron, Java Timer or Quartz message.setStringProperty(ScheduledMessage.AMQ_SCHEDULED_CRON, "30 * * * *"); message.setLongProperty(ScheduledMessage.AMQ_SCHEDULED_DELAY, 10*1000); message.setLongProperty(ScheduledMessage.AMQ_SCHEDULED_PERIOD, 10*1000); message.setIntProperty(ScheduledMessage.AMQ_SCHEDULED_REPEAT, 9);
  • 47. Future (ActiveMQ 6.0) New Java/Scala Core - fast, scalable, modular Modular design - OSGi friendly, Hot Deployment, Dynamic Configuration New Stores (Apache Cassandra - replicated datacenter store) New Protocols (AMQP 1.0, Beanstalkd, Stomp 1.1 and 2.0) Better Web (RestMQ, WebHooks, WebSockets)
  • 48. Conclusions Dynamic community Leading in terms of messaging innovation Built for Enterprise Scalable, Good Performance, Reliable
  • 49. Questions? ActiveMQ Web sites: http ://activemq.apache.org / http ://fusesource.com/products/enterprise-activemq / Blog: http://www.nighttale.net / Twitter: http ://twitter.com /dejanb http://twitter.com/fusenews

Editor's Notes

  1. optimizeAck 65% with AUTO DUPS_OK_ACK 50%