2. Agenda:
• What is OpenMQ ?
> Basic Concepts
> Product Features
> High Availability Architectures
• OpenMQ Roadmap
• Selected Customer Scenarios
• More information
Copyright Sun Microsystems Inc. All Rights Reserved. [2]
3. What is OpenMQ ?
Copyright Sun Microsystems Inc. All Rights Reserved. [3]
4. Open MQ Basics
• Allows heterogenous applications to reliability and
asynchronously pass data between each other.
• Open Source Java Message Service (JMS)
implementation (+ additions)
• Default Messaging Provider for Glassfish
• Also can be used on its own for standalone JMS
applications
• Enterprise level quality (>8 years in development)
• Open Source since JavaOne 2006
• Also available in a supported product (SJSMQ)
Copyright Sun Microsystems Inc. All Rights Reserved. [4]
5. OpenMQ Information
• The open source version of Java MQ
> Includes all features from Java MQ
• Available from http://mq.dev.java.net
• Developer and User discussion forums
• Stable builds with product releases
• Early access, promoted builds available
> New features, and fixes
• Dual license support (GPL V2 and CDDL)
Copyright Sun Microsystems Inc. All Rights Reserved. [5]
6. OpenMQ Specifications:
• Java Message Service (JMS) 1.1 Specification, JSR
914
• J2EE specification 1.3 or later
• Java Connector Architecture (JCA) for the openMQ
resource adapter (JMSRA)
Copyright Sun Microsystems Inc. All Rights Reserved. [6]
8. What Is JMS ?
• A Java-based api for Message Oriented
Middleware.
• It use the following concepts (among others)
> Message Order is guaranteed
> Level of reliability is determined when the message is
sent
> Transactions (grouping of messages to be sent or
produced together) are supported
> Format of the message is defined by the producer
> Provides two styles of message delivery (point-to-point
and publish-subscribe)
Copyright Sun Microsystems Inc. All Rights Reserved. [8]
9. How Does JMS Work?
Copyright Sun Microsystems Inc. All Rights Reserved. [9]
10. 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 Sun Microsystems Inc. All Rights Reserved. [10]
12. What are the pieces of OpenMQ
Broker The server component of OpenMQ
which handles reliable delivery
Client Allows clients to connect to the
implementations OpenMQ Broker
JMX api Full administration Api for custom
applications
Administration Allows administrators to control
Tools OpenMQ
Copyright Sun Microsystems Inc. All Rights Reserved. [12]
13. OpenMQ Architecture
Copyright Sun Microsystems Inc. All Rights Reserved. [13]
14. (*)
Product Features
* as of OpenMQ 4.3 (releasing 12/15/2008)
Copyright Sun Microsystems Inc. All Rights Reserved. [14]
15. Connectivity in OpenMQ
• JMS API
• C API
• Clients connect via
TCP/TLS or SOAP /
HTTP
• JCA Resource Adapter
JMSRA. Also used w/
> JMSJCA RA
> Generic RA
• UMS
Copyright Sun Microsystems Inc. All Rights Reserved. [15]
16. 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 Sun Microsystems Inc. All Rights Reserved. [16]
17. Deploying and Administering
• Administration tools
• JMX API
• Support for both file and JDBC-based message
stores
• Dead Message Queue (DMQ)
• XML Validation
• Topic Wildcard Support
Copyright Sun Microsystems Inc. All Rights Reserved. [17]
18. Securing OpenMQ
• Authentication
> Allows administrators to set up a user-name/password
database to control access to the system
> Supports use of JAAS for pluggable authentication
• Authorization
> Allows administrators to control which users can access
(produce or consume to) specific destinations
• SSL connection support
> Provides encryption of data to and from the server
Copyright Sun Microsystems Inc. All Rights Reserved. [18]
19. Clustering OpenMQ – Definitions
• Broker Failover:
> Manual – requires administrators intervention
> Automatic – does not require intervetion
• 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 Sun Microsystems Inc. All Rights Reserved. [19]
20. 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 Sun Microsystems Inc. All Rights Reserved. [20]
21. Clustering OpenMQ
There are currently three ways to get availability with
OpenMQ:
• Standard Clustering
> Provides service availability
• Sun Cluster Data Service for Java MQ
> Provides data availability using a highly available file
system.
• JDBC-based High Availability
> Provides service and data availability by using a highly
available database
Copyright Sun Microsystems Inc. All Rights Reserved. [21]
22. OpenMQ Features
Recent Additions:
• Stomp Support examples
• Extensive UMS Examples
• Spring Examples
Planned near-term additions:
• Visual VM support
• Improved netbeans support
• A swing and web based monitoring demo using JMX
Copyright Sun Microsystems Inc. All Rights Reserved. [22]
23. UMS: new for 4.3
Copyright Sun Microsystems Inc. All Rights Reserved. [23]
24. What is UMS ?
Copyright Sun Microsystems Inc. All Rights Reserved. [24]
25. What is UMS? (lower level)
Copyright Sun Microsystems Inc. All Rights Reserved. [25]
26. UMS – the 10k foot view
• Simple API
> 6 messaging services (e.g. login, send, receive)
> Only 2 are required to produce or consume messages
> Services are request/reply
> Only supports text messages
• Runs on top of HTTP(s)
• Multiple clients share a single JMS Connection
> Default is 100 per connection
• 2 style of queries are available:
> Simple Messaging – for non-XML text messages
> XML Messaging – for XML encoded messages
Copyright Sun Microsystems Inc. All Rights Reserved. [26]
27. UMS Interface Types
• Simple Query String
> POST /ums/simple?service=send&
destination=simpleQ&domain=queue
Send msg: Hello World!
• XML Document
<SOAP-ENV:Envelope xmlns:SOAP-ENV=quot;http://schemas.xmlsoap.org/soap/
envelope/quot;>
<SOAP-ENV:Header>
<ums:MessageHeader xmlns:ums=quot;https://mq.dev.java.net/umsquot;
ums:id=quot;1.0quot; ums:version=quot;1.0quot;>
<ums:Service
ums:service=quot;sendquot;
ums:destination=quot;XMLmessagingQquot;
ums:domain=quot;queuequot;
ums:sid=quot;7-LTgxMDczMTczNQ== quot;/>
</ums:MessageHeader>
</SOAP-ENV:Header>
<SOAP-ENV:Body><bodyvalue>Hello, XML World!</bodyvalue></SOAP-ENV:Body>
</SOAP-ENV:Envelope>
Copyright Sun Microsystems Inc. All Rights Reserved. [27]
29. Standard Clusters - Architecture
Copyright Sun Microsystems Inc. All Rights Reserved. [29]
30. Standard Cluster – Key Points
• Provides service availability
• Delivery of messages is transparent to client and
administrator
• A new broker can be manually started on the same
data if a failure occurs.
Copyright Sun Microsystems Inc. All Rights Reserved. [30]
31. Using SunCluster – Single Broker
Producer Q1 Consumer Q1
To the JMS
Broker clients, the
active/standby
configuration is
hidden
Active Standby
Sun Cluster Data Service
Local or SAN Storage
Copyright Sun Microsystems Inc. All Rights Reserved. [31]
32. Using Sun Cluster – Three Brokers
Producer Q1 Producer Q2
JDBC or
File Store
Broker A Broker B
Master
Broker C
Consumer Q1 Consumer Q2
Copyright Sun Microsystems Inc. All Rights Reserved. [32]
33. SunCluster – Key Points
• Provides availability and monitoring
• A new broker is automatically started to take over
the existing data from the unavailable one
• Relies on a shared storage device (SAN)
• Can be support for distances over 200k
Copyright Sun Microsystems Inc. All Rights Reserved. [33]
34. JDBC High Availability - Architecture
Copyright Sun Microsystems Inc. All Rights Reserved. [34]
35. JDBC High Availability – Key Points
• Simple to configure and set up
• How it works:
> Keeps all information in a single accessible location
> Stores data by broker
> Allows another broker to “takeover” the messages
> Helps prevent “split-brain” through database heartbeats
• Supported available databases
> Oracle 9i,10g (RAC or replicated with Sun Cluster)
> HADB
> MySQL Cluster
Copyright Sun Microsystems Inc. All Rights Reserved. [35]
36. OpenMQ Clustering – Comparison
Feature Cluster SunCluster JDBC HA
Data Availability No Yes Yes
Active/Active N/A No Yes
Handles Remote sites Yes Yes No [1]
HA Filesystem No Yes No
Requires HA Database No No Yes
Scales to large # of brokers Yes Yes Yes
Performance High High Low
Complexity Low High Low [4]
Takeover speed N/A Medium Fast [3]
When Available Now Now Now
Minimum # of Brokers 2 2 2
Redundant Network No No[2] No [2]
[1] May require Sun Cluster [2] May be required by supporting software
[3] Fast for broker take-over. DB recovery may be [4] medium if cannot use existing JDBC
slow infrastructure
Copyright Sun Microsystems Inc. All Rights Reserved. [36]
38. Crane (MQ 4.4)
• Targeted Spring 2009
• Features in evaluation for Crane:
> Journaling (storage of message history)
> Connected Clusters
> JMX support via UMX
> Ability to Embed the broker in a standalone application
> Performance improvements
> Support for grouping message delivery (e.g. Units of
Work)
> Web-based administration
> Scalable destinations
> JMS Bridge
Copyright Sun Microsystems Inc. All Rights Reserved. [38]
39. Phoenix (MQ 4.5)
•Targeted late 2009/early 2010
•Phoenix is too far out to have a list of possible features
but we are thinking about:
• Features pushed forward from Crane
• Encrypted Destinations
• XML Content based selectors
• Improved MySQL support
• Replay of Journaled Messages
Copyright Sun Microsystems Inc. All Rights Reserved. [39]
40. Selected Customer
Architectures
Copyright Sun Microsystems Inc. All Rights Reserved. [40]
41. Customer 1:
Copyright Sun Microsystems Inc. All Rights Reserved. [41]
42. Customer 2:
Copyright Sun Microsystems Inc. All Rights Reserved. [42]
43. Customer 3:
Copyright Sun Microsystems Inc. All Rights Reserved. [43]
44. Customer 4:
Copyright Sun Microsystems Inc. All Rights Reserved. [44]
45. Customer 5:
Copyright Sun Microsystems Inc. All Rights Reserved. [45]
47. OpenMQ -- More Information
• Visit the product webpage
> http://sun.com/software/products/message_queue
• Join the Open Message Queue project
> https://mq.dev.java.net
• Browse the product documentation
> http://docs.sun.com/app/docs/coll/1307.3
• Take the free technical training
> http://www.sun.com/training/catalog/courses/WMT-SMQ-1491.xml
Copyright Sun Microsystems Inc. All Rights Reserved. [47]
48. Related Information
• Java Composite Application Platform Suite
> http://sun.com/software/javaenterprisesystem/javacaps/
• Java System Identity Manager
> http://sun.com/software/products/identity
• Project GlassFish
> https://glassfish.dev.java.net/
• The Aquarium, A community forum
> http://blogs.sun.com/theaquarium/
Copyright Sun Microsystems Inc. All Rights Reserved. [48]