0% found this document useful (0 votes)
120 views20 pages

Open Message Queue: Alexis Moussine-Pouchkine Glassfish Team

Java Message Service (JMS) API is a Java Message Oriented Middleware (MOM) API for sending messages between two or more clients. A messaging server implements JMS.

Uploaded by

obourdon
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as ODP, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
120 views20 pages

Open Message Queue: Alexis Moussine-Pouchkine Glassfish Team

Java Message Service (JMS) API is a Java Message Oriented Middleware (MOM) API for sending messages between two or more clients. A messaging server implements JMS.

Uploaded by

obourdon
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as ODP, PDF, TXT or read online on Scribd
You are on page 1/ 20

Open Message Queue

Alexis Moussine-Pouchkine
GlassFish Team

1
Open Message Queue
• http://mq.dev.java.net
• Member of GlassFish project community
• The JMS Provider distributed with GlassFish
• Complete source; Stable and Promoted builds
• Community feedback, commentary, updates
• Open Source since 2006
> 8-year old product, enterprise quality

Copyright 2009 Sun Microsystems Inc. 2


What is JMS?
• A Java API for Message Oriented Middleware
• From Wikipedia
> Java Message Service (JMS) API is a Java Message
Oriented Middleware (MOM) API for sending messages
between two or more clients. JMS is a specification
developed under the Java Community Process as JSR
914.
• A messaging server implements JMS
> Each product can have unique implementation details
and features, beyond what is required by JMS
• Other language APIs exist, but are not standardized
Copyright 2009 Sun Microsystems Inc. 3
Messaging Models
• Java Message Service defines two messaging
models:
> Publish-subscribe (or pub-sub)
– One-to-many messaging.
– Every message goes to all interested consumers.
> Point-to-point
– One-to-one messaging.
– A single message goes to only one consumer.

Copyright 2009 Sun Microsystems Inc. 4


Messaging Models (continued)

Copyright 2009 Sun Microsystems Inc. 5


What's Available from Open MQ
• Complete stand-alone messaging server
• Fully supports JMS
• GUI installer or zip, file-based install
• Command line and GUI administration tools
• Full JMX Monitoring
• Provides many additional features (beyond JMS)
• JCA 1.5 compliant resource adapter
• Security features (ACLs, File and LDAP passwords)
• Multiple persistent stores available: file or JDBC
Copyright 2009 Sun Microsystems Inc. 7
More OpenMQ Features
• Dead Message Queue
• Message Body Compression
• Configurable acknowledge modes
> Tunable for performance
• Destination controls
> Message count limits
> Limits on number of consumers
• XML message validation
> Reject is validation fails
• Wild-card Topic Destinations
Copyright 2009 Sun Microsystems Inc. 8
Supported platforms (as of 4.3)
• Sun Solaris 9, 10 – SPARC, x86 – 32 or 64 bit
• Linux – Red Hat 4 & 5
• Windows – XP, Vista, 2003 Server, 2008 Server
• AIX – 6.1
• Ubuntu and Mac OS X via GlassFish distros
• JDBC Databases
> MySQL (Community, Enterprise Cluster)
> Oracle 10, 11
> HADB (GlassFish Enterprise Server, HA Profile)
> Java DB
> Postgresql
> DB2 (AIX Only)
• JDK 1.5, 1.6.0_10 Copyright 2009 Sun Microsystems Inc. 9
OpenMQ and GlassFish
• Integration based on a Resource Adaptor (JMSRA)
• OpenMQ 4.3 is integrated in GlassFish v2.1
• OpenMQ HA support with enterprise profile
• Optimized, embedded deployment when used in
GlassFish Developer profile
> Direct memory access (vs. network stack)
• Overall, three types of integration with GlassFish
> Embedded
> Local
> Remote
Copyright 2009 Sun Microsystems Inc. 10
System block diagram

Well organized and easy to browse source


Copyright 2009 Sun Microsystems Inc. 11
OpenMQ languages

*: UMS is from the 4.3 release in December 2008


Copyright 2009 Sun Microsystems Inc. 12
Universal Message Service (UMS)
• Simple API that can be used to send messages
from a JMS provider to both JMS and non-JMS
clients
> 6 messaging services (e.g. login, send, receive)
> Only 2 required to produce or consume a message
• Runs on top of HTTP(s)
• Allows Transactions and Reliability
• Text Message support only
• Has two types flavors of the APIS:
> Simple Messaging - for non-XML text messages
> XML Messaging - for XML encoded messages
Copyright 2009 Sun Microsystems Inc. 13
UMS is not a JMS replacement
• Use UMS for low volume clients
> Particularly useful with scripted applications
> Suitable for many clients, each at relatively low volume
– Client messaging measured in messages per minute
– Tens of Thousands of active clients, perhaps more
> No client runtime to distribute or manage
• Use JMS (Java or C) for traditional settings
> Highest throughput, supports (relatively) fewer clients
– Client messaging measured in hundreds to thousands per second
– Hundreds to thousands of clients
> Much richer control
> Runtime deployment must be managed
Copyright 2009 Sun Microsystems Inc. 14
Scaling in OpenMQ
• Support for 1000s of connections on a single broker
• Support for clusters of multiple brokers
• Message size limited only by operating system and
storage capacity
• Support for multiple receivers on a queue
• Ability to set size and behavior limits on a
destination to prevent memory issues
• No-acknowledge mode for performance when
reliability is not an issue
• Support for message compression
Copyright 2009 Sun Microsystems Inc. 15
Clustering OpenMQ – Definitions
• Broker Failover:
> Manual – requires administrators intervention
> Automatic – does not require intervention
• High Availability Definitions:
> Service Availability- support to allow applications to
continue to operate (produce and consume messages)
rapidly after a failure (Automatic failover)
> Data Availability – data is available after a failure
• OpenMQ provides support for both service and data
availability.
• Clients fail-over to other brokers in the cluster
Copyright 2009 Sun Microsystems Inc. 16
Clustering OpenMQ
• Standard clustering provides scaling and service
availability
> Allows multiple brokers to be connected together and
operate
> JMS semantics are preserved
> Producers and consumers can attach to different brokers
> If data is available, administrators can start a broker to
dispatch the messages on another machine
• OpenMQ also provides additional clustering modes
to provide multiple levels of data availability

Copyright 2009 Sun Microsystems Inc. 17


Clustering OpenMQ – 3 options
• Standard Clustering
> Provides service availability
> A new broker can be started on the same data upon
failure
• Sun Cluster Data Service for Java MQ
> Provides data availability using a highly available FS
> A new broker is automatically started to take over the
existing data from the unavailable one
> Relies on a shared storage device (SAN)
• JDBC-based High Availability
> Provides service and data availability by using a highly
available database (HADB, MySQL cluster, Oracle 10g)
Copyright 2009 Sun Microsystems Inc. 18
Want More Information?
• It all starts at the community site
> http://mq.dev.java.net
• Complete documentation is available
• Free Online training courses are available

• E-mail us at
> [email protected]
• Forum at
> http://forum.java.sun.com/forum.jspa?forumID=711
Copyright 2009 Sun Microsystems Inc. 20
TODO
• Hermes JMS

Copyright 2009 Sun Microsystems Inc. 21


Open Message Queue
http://mq.dev.java.net

[email protected]
http://blogs.sun.com/alexismp

22

You might also like