Thursday Jun 19, 2014

JMS over WebSocket

Any application server which conforms to the Java EE Full Profile needs to include a messaging provider which supports the JMS API. Open Message Queue (aka Open MQ), the world first JMS 2.0 compliant MOM (Message Oriented Middleware), is the JMS provider for GlassFish. As GlassFish, Open MQ is open source too. Currently, GlassFish 4.0 is using Open MQ 5.0. In GlassFish 4.0.1, we plan to move to Open MQ 5.0.1. The 5.0.1 release comes with a set of fixed issues (see here) but also introduces new features such as WebSocket and STOMP support. 

The JMS specification is a messaging API and as such, it doesn't define the protocol to use on the wire. It is up to the JMS implementer to decide how to handle this. Open MQ supports socket TCP connections, it also supports HTTP/S tunnelling to make JMS messages easily flows through firewalls (See Annex C of the Open Message Queue Administration Guide).

With Open MQ 5.0.1, it is now possible to use WebSocket as the communication protocol between a client and an Open MQ JMS broker. Under the hood, Open MQ uses Grizzly and Tyrus.

A Java client will continue to use the JMS API so this is transparent. The only thing you have to take care is to specify, in your connection factory, the WebSocket URL of the Open MQ JMS Broker (imqAddressList=mqws://<broker-host>:<broker-ws-port>/<ws-service-name>). 

In addition, Open MQ 5.0.1 introduces 2 additional types of WebSocket clients, i.e. 'non JMS' clients that can be used to exchange messages with applications that do use JMS : 

  • mqstomp : Any (WebSocket) client that support STOMP 1.2 protocol
  • mqjsonstomp : Any (WebSocket) client that can sends JSON formatted STOMP 1.2 protocol
Those new types of clients are particularly interesting as they open the space for new scenarios (e.g.. simple JavaScript clients). The only thing the client need to have, in order to exchange messages with JMS applications, is STOMP and WebSocket support.

To find out more about this, you can check the 'JMS and WebSocket for Lightweight and Efficient Messaging' session that was presented during last JavaOne. You can also download and try Open MQ 5.0.1 today.

Friday Dec 23, 2011

Some JMS and OpenMQ for the holidays

JMS and OpenMQ seems to be a recurring topic on the GlassFish forums and mailing-list so we've now made the content of a fairly recent bootcamp available for everyone to play with to become familiar with the technology.


The bootcamp covers basics on OpenMQ and how it relates to GlassFish, sending and receiving JMS messages, using MDB's (message-driven beans), setting up an MQ broker using a GlassFish instance or a GlassFish Cluster.

Just what you needed for the holidays!

Thursday Feb 10, 2011

Two OpenMQ screencasts

OpenMQ is both the JMS reference implementation and a key component of GlassFish. Specifically, OpenMQ 4.5 is the version integrated in GlassFish 3.1 and just like GlassFish goes way beyond what the specification requires, especially with regards to clustering, OpenMQ offers high availability clusters and useful management tools.

We've just posted two MQ screencasts which were produced a little while ago but content still relevant :
GlassFish Message Queue - High Availability Clusters
GlassFish MQ - UMS (Universal Message Service) demo (earlier post on UMS)


Expect more screencasts with the release of GlassFish 3.1 as well as complete documentation for how to setup complete GlassFish + MQ clusters.

Thursday Mar 04, 2010

GlassFish in February


The breadth and depth of the community is nicely illustrated by the variety of recent GlassFish-related blog posts. First, long time GlassFish supporter Masoud has a very detailed (it's actually a chapter of a book) OpenMQ from A to Z entry. On the operations side, Byron has a set of two posts on How to Run GlassFish V3 as a Service on Linux Ubuntu/Debian and a follow-up on using a non-root Service (see also thisGentoo variation by Jason), while Felipe's on provisioning GlassFish v3 resources with asadmin.

In the "nice words" category, Juliano has a nicely written "Java Enterprise Development - 2010 style" piece and Maksim says "GlassFish is becoming new de facto standard in Java applications. Development with new GlassFish v3 server and Eclipse now is really fast and comfortable. Server starts within a second, JEE6 is fully supported and hot code replacement works as it should.".

On the Java EE 6 and web tier side we have Bobby sharing a tool for exploring the platform, Aleksey discussing a "Grizzly 2.0: simple authentication example", while Justin puts GlassFish embedded to work with Wicket. Rene has a two-part article on running a Java EE 6 Client Application with Netbeans 6.8 and GlassFish V3 - Part 1: Creating a Basic Application and Part 2: Enhancing and Deploying the Application while Jacob goes through the simple setup to have GlassFish and Intellij 9 work together.

So while we wait for the GlassFish roadmap, we've seen one of the busiest month ever for February on the user mailing list and this recent message from the GlassFish Product Management "GlassFish, and by extension, Metro, are strategic Oracle products". Exciting times ahead!

Thursday Oct 29, 2009

GlassFish v2.1.1 is Now Available

GlassFish v2.1.1 is out (Sun Distro, Community Distro). GFv2.1.1 is the foundation for SailFin v2 and includes refinements on Replication and Failure detection plus many (>200) bug fixes and other improvements. See Shreedhar' s Overview, Kevin's post, the Wiki page and PR @Oracle OpenWorld.

GFv2.1.1 also includes OpenMQ 4.4, Grizzly 1.0.30 (changes), Jersey 1.0.3 (changes), Shoal 1.1 (changes) and JSF 1.2_13. The bulk of the changes are from the GF repository (changes).

The commercial offering is via the GlassFish Portfolio. Note that GFv2.1.1 is also a patch for earlier releases (GFv2.1, itself a patch for GFv2U2) but the patch has not yet published at SunSolve. I'll post an entry at GlassFishForBusiness when it becomes available.

Wednesday Oct 28, 2009

SailFin 2.0 is Now Available! Also GlassFish v2.1.1

Today was the release of SailFin v2 (download, home, wiki) and its companion Sun GlassFish Communications Server 2.0 (download, home). SailFin v2 is a big release; it leverages GlassFish v2.1.1 (more tomorrow) and adds a number of features including high availability, rolling upgrade, flexible network topology, better overload protection, Diameter support, improved diagnosability, Java based DCR files for the load balancer, and more.

I can't cover SailFin v2 properly but I'll collect some of the relevant links so you can follow them up.  Start with Binod's overview: SailFin v2 Released! and move from there:

Some of the major changes are:

As part of the release, the team has posted a number of new entries, including:

Older posts worth checking include:

Finally, a list for PR/Press reports:

Note - GlassFish v2.1.1 is also available from Sun's Download Center and from the Community Site. More on that release tomorrow. And the OpenMQ 4.4 (and 4.4.1 RC1) are available from here.

Friday Jul 03, 2009

OpenMQ Roadmap Updated


Ed has updated the Roadmap for OpenMQ with the information related to OpenMQ 4.4, targeted for GlassFish v3. Key features include:

• JMS Bridge -- Connect to other Open MQ clusters, or other JMS products
STOMP -- use the Streaming Text Oriented Message Protocol in Open MQ
• Embedding -- Use Open MQ as an embedded messaging provider in your own Java application

Full details at OpenMQ 4.4 Feature Page.

Saturday Jun 20, 2009

JMS over HTTP on GlassFish (and OpenMQ)


Masoud has a nice Detailed Writeup explaining how to configure OpenMQ (the GlassFish JMS implementation) to run over HTTP. This is very useful in constrained situations, for example...

An untrusted applet can communicate back to a server which it is initiated from (server which hosted the applet and delivered the .class and jar files). So your applet can either use mq protocol or it can use JMS over HTTP protocol which is shown in the sample.

BTW, Masoud also briely mentions the new UMS feature in OpenMQ and positions it relative to JMS over HTTP. Full details in Masoud's Writeup.

Thursday Mar 26, 2009

OpenMQ... From 55 King William Street


Linda has provided great information on OpenMQ in the past (see OpenMQ@TA and her Santa Webinar). I'm looking forward to new posts from Linda but, in the meantime, Nigel is Joining the Blogosphere.

Nigel's first post is on Consumer flow control and Message-Driven Beans where he describes "how to configure consumer flow control for messages delivered to MDBs running in an application server such as Glassfish".

The note is really a mini-article that covers Message pre-sending, Consumer Flow Control and Connection Flow Control and includes plenty of details and illustrative diagrams.

Welcome to the Blogosphere, Nigel!

Monday Mar 09, 2009

What's new in OpenMQ 4.3? UMS!

UMS Architecture

Going back a little bit to the GlassFish v2.1 release (January 2009), if you're into JMS (the most under-used Java EE technology IMO) it's important to notice that OpenMQ 4.3 is now shipping with this latest version of the application server (full documentation here). The most obvious new feature listed in the Release Notes is UMS (Universal Message Service).

Universal Message Service (UMS) is documented here and offers access to Message Queue from any HTTP client. OpenMQ ships with C#, Python and Ajax examples which are also featured in this nice screencast demo (last in the series of videos). Performance-wise, UMS is not a replacement to the existing C and Java APIs but still a nice addition to GlassFish 2.1 and MQ 4.3.

OpenMQ was recently highlighted on The Aquarium TV (archive). You can find a quick overview of version 4.3 (and what led to this release) on the GlassFish Podcast in episode #26. Also, make sure you listen to Linda's "Santa Claus" presentation in the following episode (#27). Well worth the time for anyone interested in JMS architectures.

Tuesday Jan 20, 2009

OpenMQ Presentations and Screencast - Now Available


I've uploaded the multi-media recordings from the Jan 9th, 2009 presentation on OpenMQ 4.3 and the new Universal Messsaging System REST API. Video recordings are available as FLV, Quicktime, iPod/320x240 and Audio only, screencast as Quicktime/MP4, slides in PDF and SlideShare.

Feedback always welcome.

PS. despite the fact that 6 of the last 9 entries are about webinars, we do carry other news too! :-)

Sunday Jan 04, 2009

Jan 9th Webinar - OpenMQ 4.3


Our first webinar of 2009 is this Friday (not Thursday!), Jan 9th, 11:00 am PT. Ed Bratt and Linda Schenider will provide an overview of the recent OpenMQ 4.3 release (to be included in GFv2.1 and GlassFish ESB) and will go into more details on the new Universal Messaging Service showing examples of its use from AJAX, C# and Python.

Slides and other material will be posted to the Presentation Page - if you have any questions ahead of the presentation, please add them as comments there, or just ask them during the presentation via the chat.

Wednesday Dec 17, 2008

OpenMQ 4.3 Now Available - Includes Universal Message Service


OpenMQ 4.3 is now available (download). This release will be included in GlassFish v2.1 but also is useful on its own. One of the most interesting pieces is the new http-based Universal Messaging Service which can be used to access OpenMQ from a browser using AJAX, as well .Net, Python, Ruby, and many others (including Java!) - see Intro, Samples, Protocol and Configuration.

Other functionality includes new platforms (AIX, Oracle 11g, Windows Vista, Windows Server 2008), a new installer, and additional Samples for things like talking to HermesJMS and STOMP.

Sun's distribution of OpenMQ still uses the "Sun Java System" brand but it follows the standard GlassFish Enterprise Business Model - see Product Page, Documentation and Downloads. And you can can purchase Commercial Subscription Support.

Wednesday Dec 03, 2008

The New Docs.Sun.Com

ALT DESCR has been around for a long time and its look-and-feel had not been updated significantly for a bit. But today it sports a New Look and it looks very good! Check these out:

GFv2, GFv2 U1/U2, GFv3 Prelude
Portal 7.2, JavaCAPS, MQ, and much more
• Nice dynamic browsing and improved searching.
• Localized in 12 languages!

Very nice! I would only want to have the ability to annotate the documents, otherwise, this looks very good!

Added - Also check out Susan's Overview of the changes.

Sunday Oct 26, 2008

... The Best AppServer, New MQ Site, MySQL in NB, SocialSite and REST, Compliance Manager, OpenStorage and SSDs

A compilation of today's news of interest:

Radio Receiver Icon

Any Best poll is always subjective in one way or another, so here are two more :-) First What's the Best AppServer - with several references to GlassFish. The second is a question from a prospective GF user that elicited a Very Nice Testimonial... which is a good time for a call for Adoption Stories; if you have any, drop us a mail at stories at sun dot com.

The OpenMQ community page sports a new, clearner-looking OpenMQ WebSite. I hear they also have testimonials and performance numbers cooking; stay tuned.

The Identity folks at Sun have released a new Compliance Manager product that elicited good press coverage (BusinessWire, SearchSecurity). This is part of Sun's Identity Products, and, like with OpenSSO, I expect the usability and applicability - not just the functionality - of all these products to continue to spread in the future.

NetBeans 6.5 (now in RC) has improvements in MySQL support, including knowing about the Sakila sample, improvements to the SQL Editor, SQL code completion, displaying multiple rowsets, and SQL history. Check out Andrei's NetBeans.TV Screencast, and thanks to John for the tip.

Roy (Fielding) has specific objections to the RESTful API for OpenSocial - see Roy's note and Dave's links (Roy points the comment to SocialSite, but it really is about OpenSocial). It seems there is a discussion thread on the OpenSocial group discussing how to incorporate that feedback into the spec.

Finally, on the OpenStorage side, a couple of good videos discussing the role of Flash in Storage, (both available in two sizes): Bill Moore ([medium], [ipod]) and Andy Bechtolsheim ([medium], [ipod]). The ipod-sized presentation are ideal for flights :-)