I would like to deploy MDB on JBOSS. But the publisher will not send messages to the JBOSS AS, it is sending messages to IBM MQ.
Should I use JCA to integrate JBOSS and IBM MQ?
OR
Can the MDB on JBOSS AS subscribe to the topic on which IBM MQ is getting messages from publisher?
What are the advantages of one approach to another?
The recommended way to consume messages in JBoss from IBM MQ is via a Message Driven Bean (MDB). This is done by deploying the IBM JCA resource adapter (RA) in JBoss. You must use the IBM RA in JBoss as this rar file contains the IBM MQ client code that is needed for communicating with IBM MQ.
When using the MDB approach, the container (JBoss, in this case) works with the JCA to manage JMS connections, message delivery and transactions. This leaves you to only write the onMessage() method - quite a lot gets done for you under the hood.
Yes you can certainly have an MDB in JBoss that is subscribed to a Topic on MQ,
You should deploy the WebSphere MQ Resource Adapter (WMQRA) into JBoss and then configured the WMQ RA JCA resources in JBoss (Activation Specification, Queue/Topic). This will then let you deploy your MDB, and the JCA resources will handle the connection to the WMQ Queue Manager and Queue/Topic that your messages are on.
There are a few guides on setting up the WMQ RA in JBoss around on the internet.
Related
I have created a Maven module with all configuration for ActiveMQ Artemis. I have done the same for IBM MQ.
I am building two separate jars for above modules.
Now I have added both jars to the classpath of my microservice.
I am struggling to find a way to load one of the above jar file based on some configuration such as active.broker = artemis or ibm mq.
Given that both ActiveMQ Artemis and IBM MQ provide JMS client implementations it should be relatively straight-forward to use the same JMS application with either.
Both ActiveMQ Artemis and IBM MQ JMS clients include JNDI implementations which can be used to "lookup" their respective admin objects (e.g. connection factories & destinations) in a standard way. You only need to swap the InitialContext configuration parameters when using ActiveMQ Artemis vs. IBM MQ.
Does Apache Active MQ provide Server-To-Server-Connection as IBM Websphere MQ does?
Background:
We currently have Websphere MQ 7.0.1 (CUST) installed to communicate with another remote Websphere MQ Server (GOV), which is not under our control.
The MQs hold a Server-To-Server-Connection via VPN-tunnel. We would like to replace our Websphere MQ with Apache ActiveMQ.
We have one QM-Manager with 4 queues and 3 channels.
Queues:
OUT (type remote): for sending messages to GOV
QOUT (local type transmission) that is used for OUT
IMP (local): used for receiving from GOV
DLQ: (local): dead letter queue
Channels:
conch: server connection
CUST_GOV: sender
GOV_CUST: receiver
I read a lot about bridging ActiveMQ to Websphere MQ (Client API, Resource Adapter, OSGi) with Camel.
Looks pretty easy with a Camel route, but this is at least a Client-Server setup.
E. G. https://www.shaishavparekh.com/2016/01/wmq-to-amq-bridge/
I need something that hides away the IBM proprietary channel stuff.
Now I found this entry: https://serverfault.com/questions/366743/apache-activemq-server-to-server-connection
As this is from 2012 I would like to ask, if anyone successful switched from Websphere MQ to ActiveMQ resp. is it still true that I can only use Client-Server?
ActiveMQ does not support a server-to-server connection to WebsphereMQ. As you mentioned, Camel would probably be the simplest way to get a connection between the two brokers.
To be clear, even if ActiveMQ did implement a bridge with WebsphereMQ it would almost certainly use the WebsphereMQ client so would fundamentally still be a client-server implementation. It's not really clear from your question why you want to avoid this.
I need to integrate Wildfly and Websphere MQ it means that I want send JMS message from Wildfly to Websphere MQ.
What is the best way to achieve this? Should I implement some client and sent these JMS messages directly or maybe there is similar method like JMS bridge?
An earlier question on interoperating with MQ Series and a pure open-source solution was answered partly with:
"The one exception is that WebSphere App Server Messaging Engines can interoperate with WMQ. These are pure JMS messaging engines written in Java but they understand the WMQ formats and protocols and appear to WMQ as another QMgr. So if you have WAS you can talk to WMQ without a WMQ client or another QMgr."
(http://stackoverflow.com/questions/18236860/can-we-talk-to-remote-websphere-mqseries-purely-with-non-websphere-mqseries-soft)
The documentation I've read through says that
WebSphere Application Server using WebSphere MQ link can operate with a service integration messaging engine or queue-sharing group.
So as I understand it, if you have WAS and WebSphere MQ link you could connect an WebSphere esb to an exterior MQ Series QMgr and look like a QMgr to that exterior MQ Series QMgr.
Without a WebSphere esb though can WAS act like a MQ QMgr and somehow manage third-party JMS messaging providers like ActiveMQ?
Thanks for any help
I believe you are mixing up capabilities.
WAS can absolutely appear to WMQ as another QMgr when using the WMQ Link. The QMgr appears to WAS in this configuration as another Service Integration Bus.
Service Integration Bus or SIB is the WAS abstraction for a JMS transport provider. It isn't the same thing as IBM's Enterprise Service Bus (ESB) product. Both talk to WMQ but WAS is in no way dependent on the ESB product to do so.
Either WMQ or any other pure JMS transport can be configured in WAS as a Foreign JMS Provider. The administrator points WAS to the JMS classes provided by the transport provider. These can include Active MQ.
There is no concept of WAS seeing WMQ but managing some other transport such as Active MQ. WAS can use normal JMS API calls to interact with Active MQ or any other transport provider. It can also make use of whatever administration API is provided by that transport provider using that provider's administration API. Since both WAS and MQ are IBM products, the integration is a bit tighter between them which is why you can use WMQ natively whereas other JMS transports must be configured as foreign JMS providers.
Currently I am working on a JMS application. But I use plain JMS API and Property file for configurations. My application is running in Weblogic and connects to MQ series server of my client.
Recently I got to know I can use Weblogic for JMS configurations.
Please explain.
What is "Foreign JMS provider"?
Is Weblogic also a JMS server or Foreign JMS provider or Both?
Weblogic provides the JMS Server features fully compliant with all JMS spec elements such as ConnectionFactory and Destinations. On this JMS Server you can connect and send messages to the client's Messaging Server via a configured Destination.
In addition using Weblogic as the JMS Server gives you lot many features such as Message Retry in case of failure, setting message quotas as well as enhanced monitoring of the JMS Server to track errors. The idea is to have more configuration driven settings for performance, deadlocks, tuning, filestore or database store etc.
A full list of such features is given at http://download.oracle.com/docs/cd/E12840_01/wls/docs103/jms/fund.html#wp1071787
A Foreign JMS Provider in Weblogic is the term used to define JMS implementations other than Weblogic JMS. An example is IBM MQ in your case.
Once the Foreign Provider is configured within Weblogic, for all practical purposes within the code - it can be called as if it was on local JNDI lookup. Weblogic will make the remote calls transparent to your code. This allows you to change your destination via configuration on the Weblogic console.
You will need a Messaging Bridge within Weblogic JMS Server to connect a source destination from which messages are received, and a target destination to which messages are sent.
Some essential reading on this is at: http://download.oracle.com/docs/cd/E12840_01/wls/docs103/jms_admin/advance_config.html#wp1075917
and an example of configuring IBM MQ as a Foreign Provider is at http://www.ibm.com/developerworks/websphere/library/techarticles/0604_kesavan/0604_kesavan.html#N1011D