Author |
Message
|
yashgt |
Posted: Wed May 18, 2016 4:23 am Post subject: Why XA only in Bindings mode? |
|
|
Apprentice
Joined: 11 Nov 2014 Posts: 38
|
This article indicates that if MQ has to be used as a Transaction Manager, the application has to compulsorily use Bindings mode.
http://www.ibm.com/developerworks/websphere/library/techarticles/0601_ritchie/0601_ritchie.html
Bindings mode also means that the MQ Server and the application both have to be on the same host because it uses JNI.
My question is, what is the fundamental reason behind this requirement? Why can't MQ Manager work like JBOSS which can reside on any host and take requests for managing distributed transactions?
What prevents WMQ from supporting client connection for distributed transactions?
Thanks,
Yash |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 4:50 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
|
Back to top |
|
 |
Vitor |
Posted: Wed May 18, 2016 4:53 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Or as we say in English, nothing. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 4:58 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Vitor wrote: |
Or as we say in English, nothing. |
Well. A failure to install the right piece. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
Vitor |
Posted: Wed May 18, 2016 5:12 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
mqjeff wrote: |
Vitor wrote: |
Or as we say in English, nothing. |
Well. A failure to install the right piece. |
Which, to circle back to the OP's original question, isn't a reason why WMQ can't support XA.
That's like saying a truck can't support towing because there's no hitch on the back. Just some mount points and holes for bolts.....
 _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 5:16 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
It's a reason it can't. Maybe not a good reason...
 _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
yashgt |
Posted: Wed May 18, 2016 6:55 am Post subject: |
|
|
Apprentice
Joined: 11 Nov 2014 Posts: 38
|
Sorry. What I meant is , what prevents WMQ from supporting XA with the Transaction Manager being on a different host than the application? |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 7:33 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
yashgt wrote: |
Sorry. What I meant is , what prevents WMQ from supporting XA with the Transaction Manager being on a different host than the application? |
Nothing.
WMQ happily uses WAS as a transaction manager - and I think the resource adapter works in any other JMS server. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
bruce2359 |
Posted: Wed May 18, 2016 8:23 am Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
mqjeff wrote: |
yashgt wrote: |
Sorry. What I meant is , what prevents WMQ from supporting XA with the Transaction Manager being on a different host than the application? |
Nothing.
WMQ happily uses WAS as a transaction manager - and I think the resource adapter works in any other JMS server. |
Or, asked in a different way: can an XA transaction span multiple platforms/hosts? And, if so, how many? _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 8:31 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
bruce2359 wrote: |
Or, asked in a different way: can an XA transaction span multiple platforms/hosts? And, if so, how many? |
I don't think you can put more than one application into the same XA transaction...
But an XA transaction manager should be able to create a transaction across several databases (on different systems) as long as they are all the same flavor of database (DB2, Oracle, etc). And more than one queue manager.
How many depends on the TM.
At least according to my relatively unreliable memory. Might be easier to go check what WAS can do and then extrapolate to regular JMS/JNDI.
IIB can assemble an XA Transaction across multiple DBs (again, all of the same type) and the local qmgr. (Or whatever the broker QM is for IIB 10). _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 8:32 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
To put this all another way.
An MQ Queue Manager can be an XA Resource or an XA Transaction Manager.
An MQ client can create an XA Transaction using either the MQ ETC, or the JMS Resource Provider.
So - "Why does MQ have to use bindings mode for an XA Transaction?".
It doesn't. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
yashgt |
Posted: Wed May 18, 2016 9:01 am Post subject: |
|
|
Apprentice
Joined: 11 Nov 2014 Posts: 38
|
Rewording the question. Why are we forced to have the client application and the Transaction Manager on the same host. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 9:12 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
yashgt wrote: |
Rewording the question. Why are we forced to have the client application and the Transaction Manager on the same host. |
Restating the answer.
You aren't. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
yashgt |
Posted: Wed May 18, 2016 9:52 am Post subject: |
|
|
Apprentice
Joined: 11 Nov 2014 Posts: 38
|
The docs clearly state that with MQ ETC you can use Q Manager only as a resource. The Transaction Manager needs to be separate and on the same host as the client. So we are indeed forced to have the coordinator on same host as application |
|
Back to top |
|
 |
mqjeff |
Posted: Wed May 18, 2016 10:03 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Ah, ok.
We're getting into the subtleties of your question that I hadn't clued in on.
So, yeah. The docs say that the MQ client application has to be running on the same machine as the transaction manager, when using the MQ ETC.
They also say that the queue manager itself can be on another machine - when using an external transaction manager.
If you are using MQ as the transaction manager, then the MQ application must run on the same machine as the queue manager - because the XA functions use shared memory.
The part I didn't clue in on, and really really don't understand is this. Your JBOSS application is using JNI to call MQ.
That seems very very very odd. It seems you should just use JMS instead. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
|