ActiveMQ Artemis client on Java 1.6 - java-6

I am trying to find a workable recipe to connect to ActiveMQ Artemis from Java 1.6.
Any ideas? Any way to leverage another client and protocol to connect to Artemis?

You could possibly use a legacy HornetQ client that supported JDK 1.6. Artemis has worked to maintain backwards compatibility with HornetQ so it should work OK.
Also, you could use a STOMP client that supports JDK 1.6. STOMP is a very simple protocol so even if you couldn't find one with JDK 1.6 support you could write your own if necessary.

Related

Do Apache ActiveMQ client and server have to use the same jar file versions?

Can clients using v5.10.2 client jar files connect to an ActiveMQ v5.15.5 server?
Based on my research they will both follow the JMS v1.1 spec and so should work, though obviously missing out on some of the improvements in the newer version.
The use case is clients running older versions of Java and therefore limited to older client jar files.
Note: this implicitly answers the question but as it's not explicit am leaving my question here for somebody authoritative to answer explicitly.
JMS is not a protocol it is an API specification.
ActiveMQ client's use the OpenWire protocol which does offer cross version compatibility so Older 5.x clients should work with newer 5.x brokers. That said the combinations aren't tested so while in theory it can work in practice it is best to upgrade the clients along with the broker whenever possible.

Java code to make connection with ArtemisActiveMQ

Looking java code to connect with ArtemisActiveMQ. Earlier using HornetQ for messaging but now need to migrate on ArtemisActiveMQ.
Apache ActiveMQ Artemis ships with numerous examples. Take a look at super-simple "queue" example for a demonstration of how to use the JMS API to connect.

Client jar file version for IBM MQ7 and MQ8

Our product will support IBM MQ7 and MQ8 based on client requirement. Now, we like to know latest client jar version that we may use for our application?
We would like to use JMS 1.1 specification. I have found following link for MQ 7.5 JAR-
http://www.ibm.com/support/knowledgecenter/SSFKSJ_7.5.0/com.ibm.mq.dev.doc/q120070_.htm
Is it sufficient if we use above mentioned client jar to connect MQ 7 and MQ 8 server?
Application will use JRE 1.7 and WAS liberty 8.5.5.9.
If you are using WebSphere Liberty as your application server, then you will need to the MQ JCA Resource Adapter (MQ-RA) to make use of MQ JMS messaging. Liberty (unlike traditional WebSphere Application Server) does not ship a copy of the MQ-RA, but you can download and install one pretty easily and then link to it from within the Liberty server's server.xml configuration file. Here's a link to explain how to do this:
http://www-01.ibm.com/support/docview.wss?uid=swg21633761
Now, Liberty can use a copy of the WebSphere MQ V7.5.0.5 (or later) Resource Adapter, which only supports the JMS 1.1 API, and the Liberty feature you will want to enable with that version is "wmqJmsClient-1.1".
However, I would suggest you consider the latest version of the IBM MQ-RA (at the time of writing this is V9.0.0.0). The MQ V8.0.0.3 and V9 RAs support both the JMS 1.1 "classic" API as well as the newer 2.0 "simplified" API. Therefore you can use the newer MQ-RA levels but your JMS 1.1 application will still work perfectly fine. If using a V8 or V9 IBM MQ-RA, then the Liberty feature to enable to is "wmqJmsClient-2.0".
The V7.5, V8 and V9 MQ Resource Adapters can connect to any MQ queue manager version; the major or maintenance versions between the JMS client and the MQ server do not need to match.
For reference, here are a couple of links I recommend reading over as well:
http://www.ibm.com/support/knowledgecenter/SSFKSJ_9.0.0/com.ibm.mq.dev.doc/q031610_.htm
http://www.ibm.com/support/knowledgecenter/SSAW57_8.5.5/com.ibm.websphere.wlp.nd.doc/ae/twlp_dep_msg_wmq.html
http://www.ibm.com/support/knowledgecenter/SSAW57_8.5.5/com.ibm.websphere.wlp.nd.doc/ae/rwlp_restrict.html
I hope this helps!

Websocket support on JBoss 6

I have been exploring options to provide websocket support on JBoss 6. WebSocket was added in Java EE 7 so JBoss 6 doesn't have native support for it.
I explored other options to get websocket support on JBoss 6. One of the commonly suggested approaches is to use Atmosphere library. But found that Atmosphere on JBoss 6 falls back to long polling (doesn't support websockets). Here is the reference,link. I need websocket support and no alternatives.
My investigation so far suggests that, websockets support requires changes in transport protocol mechanism. So we can't get native support for it on JBoss 6 even by adding external jars/libraries.
Any suggestion/opinion ??
Couldn't find any reference for websocket support on JBoss 6. JBoss supports it from EAP 6.3
So going ahead with HTTP.
Which version of JBoss are you using? 6.2+ works with https://github.com/Atmosphere/atmosphere/wiki/Installing-JBoss-WebSocket-Support

java webscoket client for Rabbit mq Stomp

I am looking for creating a websocket client for using rabbit mq stomp over websocker using java.
I using jetty client and i am getting org.eclipse.jetty.websocket.api.UpgradeException: Didn't switch protocols
Looks like the issue is with the Rabbit MQ version. After I've upgraded from Ubuntu default one to the newest Rabbit MQ version from https://www.rabbitmq.com/install-debian.html it worked for me.
Look at this example: stomp-websockets-java-client
Please read first:
http://jmesnil.net/stomp-websocket/doc/
http://www.rabbitmq.com/blog/2012/05/14/introducing-rabbitmq-web-stomp/
not perfect, it's far from the worst way do messaging in the browser: exposing STOMP through Websockets.

Resources