RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-12 Thread thomas . cherel
I just submitted a patch (ID 753022).
Sample code and complete documentation to configure WSMQ in JBoss is
included:

The current status of this sample is as follow: 

MDB listening to a WSMQ queue (using a non-XA connection factory) and
sending a reply to another WSMQ queue (auto-acknowledge mode) is working. 
MDB listening to a WSMQ queue using an XA connection factory is not working.
The MDB never receives any messages (see below for more details). 
MDB listening to a WSMQ queue (using a non-XA connection factory) and
sending a reply to a JBoss queue (auto-acknowledge mode) is working. 
MDB listening to a WSMQ queue (using a non-XA connection factory) and
sending a reply to a JBoss queue (using an XA connection factory) is
working. The WSMQ queue and JBoss queue are synchronized but not in a 100%
reliable way as the WSMQ queue is not using an XA connection factory. 
MDB listening to JBoss queue (using and XA connection factory) and sending a
reply to a WSMQ queue within the same XA transaction is working. The two
queues are completely synchronized through XA. 
No tests have been done using WSMQ Topics (it requires an extra piece of
software for WSMQ).

Thomas

-Original Message-
From: Adrian Brock [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 06, 2003 8:07 AM
To: [EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

Hi Thomas,

Sounds like you have it nearly correct.

If you can post the working configuration as
a patch at www.sf.net/projects/jboss
I will include them in docs/examples/jms,
I don't have MQSeries so I can't test it.

For JNDI you have three options. 
1) Bind the external context into jboss's jndi
2  Use the following attribute in the provider config
attribute name=ProviderUrlwhatever/ProviderUrl
3) Write your own provider adapter

Re: xa-connectionfalse/xa-connection
You will need to specify this when the connection factory
you chose in the JMS provider is not an XAConnectionFactory.

Re: JMS resource adapter
You don't need to change ra.xml, these are just default values.

If you want a new JMS resource adapter, you should make a
new configuration (just like when you make a new data source).
You can specify the provider adapter as a property on the
connection manager.

3.2 style - 3.0 is too long winded :-) 
but the idea is the same.

  !-- JMS XA Resource adapter, use this to get transacted JMS in beans
--
  tx-connection-factory
jndi-nameMQJmsXA/jndi-name
xa-transaction/
adapter-display-nameMQ JMS Adapter/adapter-display-name
config-property name=JmsProviderAdapterJNDI
type=java.lang.Stringjava:MQJMSProvider/config-property
config-property name=SessionDefaultType
type=java.lang.Stringjavax.jms.Topic/config-property
 
security-domain-and-applicationJmsXARealm/security-domain-and-applica
tion
  /tx-connection-factory

Regards,
Adrian


Adrian Brock
Director of Support
Back Office
JBoss Group, LLC

  
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: 06 June 2003 05:59
To: [EMAIL PROTECTED]
Subject: [JBoss-user] JBoss XA transaction with WebSphere MQ




I have been playing with JBoss 3.0.5 and WebSphere MQ 5.3 (ex-MQSeries)
for a while now. 
I managed to create a new JMS provider in JBoss for WebSphere MQ: 
In jms-service.xml, duplicate the org.jboss.jms.jndi.JMSProviderLoader
mbean. Change the ProviderName to WebSphereMQJMSProvider, change the
QueueFactoryRef to WSMQConnectionFactory (I also changed the
TopicFactoryRef to WSMQConnectionFactory, but I did not play with
topics). I am passing the details on how to add the
WSMQConnectionFactory to the JBoss JNDI space.
I managed to create a new configuration for MDB listening to WS MQ: 
In standardjboss.xml, duplicate the Standard Message Driven Bean
container configuration. Change the name Standard Message Driven Bean to
WebSphere MQ Message Driven Bean and set the JMSProviderAdapterJNDI to
WebSphereMQJMSProvider (same as ProviderName in jms-service.xml).
After that, I can have two types of MDBs. One listening to a JBoss queue
and one listening to WS MQ queue. 
My ultimate goal is to have an MDB listening to a queue X and forward
each received messages to a queue Y. 
I want X to be a JBoss queue or a WS MQ queue. 
I want Y to be a JBoss queue or a WS MQ queue. 
I want the reading and forwarding of the message to be done within the
same transaction. 
If X and Y are JBoss queues, no problem (container transaction-type in
the MDB ejb-jar.xml and java:/JmsXA for Y connection factory).
If X is a JBoss queue and Y is a WS MQ queue, I also manage to make it
work but with a little more pain: 
- I had to change the JmsProviderAdapterJNDI config property
value in the ra.xml of the jms-ra.rar (the JMS resource adapter for XA)
in order to point to my WebSphereMQJMSProvider.
- I had to tweak the JAAS settings of the JMS XA resource
adapter in jms-service.xml (WS MQ did

RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread Danny . Yates
In MQSeries 5.2, you could only use the XAConnectionFactory if you
configured the MQSeries JMS API to use 'bindings mode' instead of
'client mode'. The upshot of this is that the MQSeries Queue Manager
and your Application Server needed to be on the same box, because
bindings mode uses shared memory to communicate.

Rgds,

Dan.

-- 
Danny Yates
 


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: 08 June 2003 08:07
To: [EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA transaction with WebSphere MQ


Thanks for the reply.
I am working on a complete readme to configure WebSphere MQ in JBoss.
I will submit it as a patch once I am done, no problem.

I am not sure to understand what you are referring to when talking about
JNDI. If this is about bringing the WebSphere MQ queue/topic and connection
factory object in the JBoss namespace, I actually wrote my own custom
MBeans, wrapped them in a sar file and deploy it. The nice thing about it is
that I have a jboss-service.xml in the sar which is similar to the
jbossmq-destinations file and which allows me to declare as many WSMQ object
as I need.

The xa-connectionfalse/xa-connection is something that I have to do to
have a WS MQ MDB working. I am not able to make the XA connection factory of
WS MQ working. If I try to use it, the MDB never receives any messages, I am
not sure to know why yet. Any suggestions at what I might need to look at?
The MDB gets deployed without any errors; my client application is sending
the message fine (I can see them in the WSMQ queue through the WSMQ admin
tool), but the MDB never receives them. I think something wrong is happening
because JBoss does not shutdown properly after that. It hangs in the
stopping of the MDB, I think.

I managed to create a new JMS resource adapter as you suggested. It seems to
work fine. I need to check if I can send a message to a JBoss and a WSMQ
queue using my two resource adapters but all in one transaction.
I did experience some problems if I change the following value in my new JMS
resource adapter: 
adapter-display-nameJMS Adapter/adapter-display-name
If it is not set to JMS Adapter, then JBoss complains about the deployment
being incomplete because of some dependencies with ConnectionManager and
pool (or something like that. I can try to find the exact message if
needed). Any ideas why?

Thanks again for the help.

Thomas



-Original Message-
From: Adrian Brock [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 06, 2003 8:07 AM
To: [EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

Hi Thomas,

Sounds like you have it nearly correct.

If you can post the working configuration as
a patch at www.sf.net/projects/jboss
I will include them in docs/examples/jms,
I don't have MQSeries so I can't test it.

For JNDI you have three options. 
1) Bind the external context into jboss's jndi
2  Use the following attribute in the provider config
attribute name=ProviderUrlwhatever/ProviderUrl
3) Write your own provider adapter

Re: xa-connectionfalse/xa-connection
You will need to specify this when the connection factory
you chose in the JMS provider is not an XAConnectionFactory.

Re: JMS resource adapter
You don't need to change ra.xml, these are just default values.

If you want a new JMS resource adapter, you should make a
new configuration (just like when you make a new data source).
You can specify the provider adapter as a property on the
connection manager.

3.2 style - 3.0 is too long winded :-) 
but the idea is the same.

  !-- JMS XA Resource adapter, use this to get transacted JMS in beans
--
  tx-connection-factory
jndi-nameMQJmsXA/jndi-name
xa-transaction/
adapter-display-nameMQ JMS Adapter/adapter-display-name
config-property name=JmsProviderAdapterJNDI
type=java.lang.Stringjava:MQJMSProvider/config-property
config-property name=SessionDefaultType
type=java.lang.Stringjavax.jms.Topic/config-property
 
security-domain-and-applicationJmsXARealm/security-domain-and-applica
tion
  /tx-connection-factory

Regards,
Adrian


Adrian Brock
Director of Support
Back Office
JBoss Group, LLC

  
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: 06 June 2003 05:59
To: [EMAIL PROTECTED]
Subject: [JBoss-user] JBoss XA transaction with WebSphere MQ




I have been playing with JBoss 3.0.5 and WebSphere MQ 5.3 (ex-MQSeries)
for a while now. 
I managed to create a new JMS provider in JBoss for WebSphere MQ: 
In jms-service.xml, duplicate the org.jboss.jms.jndi.JMSProviderLoader
mbean. Change the ProviderName to WebSphereMQJMSProvider, change the
QueueFactoryRef to WSMQConnectionFactory (I also changed the
TopicFactoryRef to WSMQConnectionFactory, but I did not play with
topics). I am passing the details on how to add the
WSMQConnectionFactory to the JBoss JNDI space.
I managed to create a new configuration

RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread thomas . cherel
Title: RE: [JBoss-user] JBoss XA transaction  with WebSphere MQ





Thanks for the information. I went through this pain already until I discovered that with MQ 5.3, service pack 3 (CSD03) and what IBM is calling the Extended Transaction Client, you are now supposed to be able to make XA work with the 'client mode' of the MQ JMS API (and this is what I am currently trying).

Did you manage to make XA work with MQ 5.2 binding mode and JBoss? I tried that as well with MQ 5.3 and I get the same problem as I currently have, the MDB is not receiving any messages.

If you have a configuration which is working, I am interested, if possible, to get some details.


Thanks


Thomas


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Monday, June 09, 2003 3:47 AM
To: [EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA transaction with WebSphere MQ


In MQSeries 5.2, you could only use the XAConnectionFactory if you
configured the MQSeries JMS API to use 'bindings mode' instead of
'client mode'. The upshot of this is that the MQSeries Queue Manager
and your Application Server needed to be on the same box, because
bindings mode uses shared memory to communicate.


Rgds,


Dan.


-- 
Danny Yates




-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] 
Sent: 08 June 2003 08:07
To: [EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA transaction with WebSphere MQ



Thanks for the reply.
I am working on a complete readme to configure WebSphere MQ in JBoss.
I will submit it as a patch once I am done, no problem.


I am not sure to understand what you are referring to when talking about
JNDI. If this is about bringing the WebSphere MQ queue/topic and connection
factory object in the JBoss namespace, I actually wrote my own custom
MBeans, wrapped them in a sar file and deploy it. The nice thing about it is
that I have a jboss-service.xml in the sar which is similar to the
jbossmq-destinations file and which allows me to declare as many WSMQ object
as I need.


The xa-connectionfalse/xa-connection is something that I have to do to
have a WS MQ MDB working. I am not able to make the XA connection factory of
WS MQ working. If I try to use it, the MDB never receives any messages, I am
not sure to know why yet. Any suggestions at what I might need to look at?
The MDB gets deployed without any errors; my client application is sending
the message fine (I can see them in the WSMQ queue through the WSMQ admin
tool), but the MDB never receives them. I think something wrong is happening
because JBoss does not shutdown properly after that. It hangs in the
stopping of the MDB, I think.


I managed to create a new JMS resource adapter as you suggested. It seems to
work fine. I need to check if I can send a message to a JBoss and a WSMQ
queue using my two resource adapters but all in one transaction.
I did experience some problems if I change the following value in my new JMS
resource adapter: 
 adapter-display-nameJMS Adapter/adapter-display-name
If it is not set to JMS Adapter, then JBoss complains about the deployment
being incomplete because of some dependencies with ConnectionManager and
pool (or something like that. I can try to find the exact message if
needed). Any ideas why?


Thanks again for the help.


Thomas




-Original Message-
From: Adrian Brock [mailto:[EMAIL PROTECTED]] 
Sent: Friday, June 06, 2003 8:07 AM
To: [EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA transaction with WebSphere MQ


Hi Thomas,


Sounds like you have it nearly correct.


If you can post the working configuration as
a patch at www.sf.net/projects/jboss
I will include them in docs/examples/jms,
I don't have MQSeries so I can't test it.


For JNDI you have three options. 
1) Bind the external context into jboss's jndi
2 Use the following attribute in the provider config
attribute name=ProviderUrlwhatever/ProviderUrl
3) Write your own provider adapter


Re: xa-connectionfalse/xa-connection
You will need to specify this when the connection factory
you chose in the JMS provider is not an XAConnectionFactory.


Re: JMS resource adapter
You don't need to change ra.xml, these are just default values.


If you want a new JMS resource adapter, you should make a
new configuration (just like when you make a new data source).
You can specify the provider adapter as a property on the
connection manager.


3.2 style - 3.0 is too long winded :-) 
but the idea is the same.


 !-- JMS XA Resource adapter, use this to get transacted JMS in beans
--
 tx-connection-factory
 jndi-nameMQJmsXA/jndi-name
 xa-transaction/
 adapter-display-nameMQ JMS Adapter/adapter-display-name
 config-property name=JmsProviderAdapterJNDI
type=java.lang.Stringjava:MQJMSProvider/config-property
 config-property name=SessionDefaultType
type=java.lang.Stringjavax.jms.Topic/config-property

security-domain-and-applicationJmsXARealm/security-domain-and-applica
tion
 /tx-connection-factory


Regards,
Adrian

RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread Danny . Yates
Title: Message



I'm 
afraid I never tried MQ with JBoss at all (XA or otherwise). We were using 
WebLogic and doing JTS transactions in client mode against a remote MQ 
server.

-- 
Danny Yates


  
  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] Sent: 09 June 2003 
  13:11To: [EMAIL PROTECTED]Subject: RE: 
  [JBoss-user] JBoss XA transaction with WebSphere MQ
  Thanks for the information. I went through this pain already 
  until I discovered that with MQ 5.3, service pack 3 (CSD03) and what IBM is 
  calling the Extended Transaction Client, you are now supposed to be able to 
  make XA work with the 'client mode' of the MQ JMS API (and this is what I am 
  currently trying).
  Did you manage to make XA work with MQ 5.2 binding mode and 
  JBoss? I tried that as well with MQ 5.3 and I get the same problem as I 
  currently have, the MDB is not receiving any messages.
  If you have a configuration which is working, I am interested, 
  if possible, to get some details. 
  Thanks 
  Thomas 
  -Original Message- From: 
  [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
  Sent: Monday, June 09, 2003 3:47 AM To: [EMAIL PROTECTED] Subject: 
  RE: [JBoss-user] JBoss XA transaction with WebSphere MQ 
  In MQSeries 5.2, you could only use the XAConnectionFactory if 
  you configured the MQSeries JMS API to use 'bindings 
  mode' instead of 'client mode'. The upshot of this is 
  that the MQSeries Queue Manager and your Application 
  Server needed to be on the same box, because bindings 
  mode uses shared memory to communicate. 
  Rgds, 
  Dan. 
  -- Danny Yates  
  -Original Message- From: 
  [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
  Sent: 08 June 2003 08:07 To: 
  [EMAIL PROTECTED] Subject: RE: 
  [JBoss-user] JBoss XA transaction with WebSphere MQ 
  Thanks for the reply. I am working on 
  a complete readme to configure WebSphere MQ in JBoss. I will submit it as a patch once I am done, no problem. 
  I am not sure to understand what you are referring to when 
  talking about JNDI. If this is about bringing the 
  WebSphere MQ queue/topic and connection factory object 
  in the JBoss namespace, I actually wrote my own custom MBeans, wrapped them in a sar file and deploy it. The nice thing about 
  it is that I have a jboss-service.xml in the sar which 
  is similar to the jbossmq-destinations file and which 
  allows me to declare as many WSMQ object as I 
  need. 
  The xa-connectionfalse/xa-connection is 
  something that I have to do to have a WS MQ MDB 
  working. I am not able to make the XA connection factory of WS MQ working. If I try to use it, the MDB never receives any messages, 
  I am not sure to know why yet. Any suggestions at what 
  I might need to look at? The MDB gets deployed without 
  any errors; my client application is sending the 
  message fine (I can see them in the WSMQ queue through the WSMQ admin 
  tool), but the MDB never receives them. I think something 
  wrong is happening because JBoss does not shutdown 
  properly after that. It hangs in the stopping of the 
  MDB, I think. 
  I managed to create a new JMS resource adapter as you 
  suggested. It seems to work fine. I need to check if I 
  can send a message to a JBoss and a WSMQ queue using 
  my two resource adapters but all in one transaction. I 
  did experience some problems if I change the following value in my new 
  JMS resource adapter: 
   adapter-display-nameJMS 
  Adapter/adapter-display-name If it is not set 
  to "JMS Adapter", then JBoss complains about the deployment being incomplete because of some dependencies with ConnectionManager 
  and pool (or something like that. I can try to find 
  the exact message if needed). Any ideas why? 
  
  Thanks again for the help. 
  Thomas 
  -Original Message- From: 
  Adrian Brock [mailto:[EMAIL PROTECTED]] 
  Sent: Friday, June 06, 2003 8:07 AM To: [EMAIL PROTECTED] Subject: 
  RE: [JBoss-user] JBoss XA transaction with WebSphere MQ 
  Hi Thomas, 
  Sounds like you have it nearly correct. 
  If you can post the working configuration as a patch at www.sf.net/projects/jboss I will 
  include them in docs/examples/jms, I don't have 
  MQSeries so I can't test it. 
  For JNDI you have three options. 1) 
  Bind the external context into jboss's jndi 2 
  Use the following attribute in the provider config attribute name="ProviderUrl"whatever/ProviderUrl 
  3) Write your own provider adapter 
  Re: xa-connectionfalse/xa-connection 
  You will need to specify this when the connection 
  factory you chose in the JMS provider is not an 
  XAConnectionFactory. 
  Re: JMS resource adapter You don't 
  need to change ra.xml, these are just default values. 
  If you want a new JMS resource adapter, you should make 
  a new configuration (just like when you make a new 
  data source). You can specify the provider adapter as 
  a property on the connection manager. 
  3.2 style - 3.0 is too long win

RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread thomas . cherel
Title: Message









WebLogic is one of my options as well.

Does it mean that you managed to have a MQ
JMS provider working within WebLogic (including having Message Driven Bean
deployed listening to MQ queues/topics) with XA/JTS support?

If yes, I am interested to know which
version of WebLogic you are using and any kind of information you can share on
setting this up in WebLogic (I do not have too much experience with WebLogic,
but I was going to try that, at some point).



Thomas 



-Original Message-
From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 09, 2003 8:36
AM
To:
[EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ





I'm afraid I never tried
MQ with JBoss at all (XA or otherwise). We were using WebLogic and doing JTS
transactions in client mode against a remote MQ server.









-- 

Danny Yates





-Original
Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: 09 June 2003 13:11
To:
[EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ

Thanks for the information. I went through this pain
already until I discovered that with MQ 5.3, service pack 3 (CSD03) and what
IBM is calling the Extended Transaction Client, you are now supposed to be able
to make XA work with the 'client mode' of the MQ JMS API (and this is what I am
currently trying).

Did you manage to make XA work with MQ 5.2 binding
mode and JBoss? I tried that as well with MQ 5.3 and I get the same problem as
I currently have, the MDB is not receiving any messages.

If you have a configuration which is working, I am
interested, if possible, to get some details. 

Thanks 

Thomas 

-Original Message- 
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]

Sent: Monday, June 09, 2003 3:47 AM

To:
[EMAIL PROTECTED] 
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ 

In MQSeries 5.2, you could only use the
XAConnectionFactory if you 
configured the MQSeries JMS API to
use 'bindings mode' instead of 
'client mode'. The upshot of this
is that the MQSeries Queue Manager 
and your Application Server needed
to be on the same box, because 
bindings mode uses shared memory to
communicate. 

Rgds, 

Dan. 

-- 
Danny Yates 
 



-Original Message- 
From: [EMAIL PROTECTED]

[mailto:[EMAIL PROTECTED]]

Sent: 08 June 2003 08:07

To:
[EMAIL PROTECTED] 
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ 



Thanks for the reply. 
I am working on a complete readme
to configure WebSphere MQ in JBoss. 
I will submit it as a patch once I
am done, no problem. 

I am not sure to understand what you are referring to
when talking about 
JNDI. If this is about bringing the
WebSphere MQ queue/topic and connection 
factory object in the JBoss
namespace, I actually wrote my own custom 
MBeans, wrapped them in a sar file
and deploy it. The nice thing about it is 
that I have a jboss-service.xml in
the sar which is similar to the 
jbossmq-destinations file and which
allows me to declare as many WSMQ object 
as I need. 

The xa-connectionfalse/xa-connection
is something that I have to do to 
have a WS MQ MDB working. I am not
able to make the XA connection factory of 
WS MQ working. If I try to use it,
the MDB never receives any messages, I am 
not sure to know why yet. Any
suggestions at what I might need to look at? 
The MDB gets deployed without any
errors; my client application is sending 
the message fine (I can see them in
the WSMQ queue through the WSMQ admin 
tool), but the MDB never receives
them. I think something wrong is happening 
because JBoss does not shutdown
properly after that. It hangs in the 
stopping of the MDB, I think.


I managed to create a new JMS resource adapter as you
suggested. It seems to 
work fine. I need to check if I can
send a message to a JBoss and a WSMQ 
queue using my two resource
adapters but all in one transaction. 
I did experience some problems if I
change the following value in my new JMS 
resource adapter: 
 adapter-display-nameJMS Adapter/adapter-display-name

If it is not set to JMS
Adapter, then JBoss complains about the deployment 
being incomplete because of some
dependencies with ConnectionManager and 
pool (or something like that. I can
try to find the exact message if 
needed). Any ideas why?


Thanks again for the help. 

Thomas 



-Original Message- 
From: Adrian Brock [mailto:[EMAIL PROTECTED]] 
Sent: Friday, June 06, 2003 8:07 AM

To:
[EMAIL PROTECTED] 
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ 

Hi Thomas, 

Sounds like you have it nearly correct. 

If you can post the working configuration as

a patch at
www.sf.net/projects/jboss 
I will include them in
docs/examples/jms, 
I don't have MQSeries so I can't
test it. 

For JNDI you have three options. 
1) Bind the external context into
jboss's jndi 
2 Use the following attribute
in the provider config 
attribute
name=ProviderUrlwhatever/ProviderUrl 
3) Write your own

RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread Danny . Yates
Title: Message



A 
while back I had it working in WebLogic 6 with JTS transaction (NOT XA 
transactions). At least I think it was JTS transactions. Essential you set the 
transactional flag to true when creating a session, and have to do 
session.commit for your writes to appear. This works in WLS 6.1 sp 4 onwards 
using their MessagingBridge (they will tell you they back-ported the 
MessagingBridge to sp2 or sp3. They only did half a job - it only works from 
sp4), or WLS7. In WLS7, I think MDBs have properties which allow you to connect 
them to any JNDI tree using a URL and Context Factory. In this case, you use the 
Sun FileSystem JNDI implementation and IBM's jmsadmin (???) tool to manage the 
FileSystem JNDI. There are plenty of papers on the web about doing 
this.

Good 
luck!

Dan.

-- 
Danny Yates


  
  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] Sent: 09 June 2003 
  14:52To: [EMAIL PROTECTED]Subject: RE: 
  [JBoss-user] JBoss XA transaction with WebSphere MQ
  
  WebLogic is one of my 
  options as well.
  Does it mean that you 
  managed to have a MQ JMS provider working within WebLogic (including having 
  Message Driven Bean deployed listening to MQ queues/topics) with XA/JTS 
  support?
  If yes, I am 
  interested to know which version of WebLogic you are using and any kind of 
  information you can share on setting this up in WebLogic (I do not have too 
  much experience with WebLogic, but I was going to try that, at some 
  point).
  
  Thomas 
  
  
  -Original 
  Message-From: 
  [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
  Sent: Monday, June 09, 2003 
  8:36 AMTo: 
  [EMAIL PROTECTED]Subject: RE: [JBoss-user] JBoss XA 
  transaction with WebSphere MQ
  
  
  I'm 
  afraid I never tried MQ with JBoss at all (XA or otherwise). We were using 
  WebLogic and doing JTS transactions in client mode against a remote MQ 
  server.
  
  
  -- 
  Danny Yates
  
  
-Original 
Message-From: 
[EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED] Sent: 09 June 2003 13:11To: 
[EMAIL PROTECTED]Subject: RE: [JBoss-user] JBoss XA 
transaction with WebSphere MQ
Thanks for the information. I went through this pain 
already until I discovered that with MQ 5.3, service pack 3 (CSD03) and what 
IBM is calling the Extended Transaction Client, you are now supposed to be 
able to make XA work with the 'client mode' of the MQ JMS API (and this is 
what I am currently trying).
Did you manage to make XA work with MQ 5.2 binding 
mode and JBoss? I tried that as well with MQ 5.3 and I get the same problem 
as I currently have, the MDB is not receiving any 
messages.
If you have a configuration which is working, I am 
interested, if possible, to get some details. 
Thanks 
Thomas 
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Monday, 
June 09, 2003 3:47 AM To: [EMAIL PROTECTED] 
Subject: RE: [JBoss-user] 
JBoss XA transaction with WebSphere MQ 
In MQSeries 5.2, you could only use the 
XAConnectionFactory if you configured the MQSeries JMS API to use 'bindings 
mode' instead of 'client mode'. The upshot of this is that the 
MQSeries Queue Manager and your Application Server needed to be on the same 
box, because bindings mode uses shared memory to 
communicate. 
Rgds, 
Dan. 
-- Danny Yates  

-Original Message- From: 
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: 08 June 
2003 08:07 To: 
[EMAIL PROTECTED] Subject: RE: [JBoss-user] JBoss XA transaction with 
WebSphere MQ 

Thanks for the reply. I am working on a complete readme to 
configure WebSphere MQ in JBoss. I will submit it as a patch once I am done, no 
problem. 
I am not sure to understand what you are referring 
to when talking about JNDI. If this is about bringing the WebSphere MQ 
queue/topic and connection factory object in the JBoss namespace, I actually 
wrote my own custom MBeans, wrapped them in a sar file and deploy it. 
The nice thing about it is that I have a jboss-service.xml in the sar which is 
similar to the jbossmq-destinations file and which allows me to 
declare as many WSMQ object as I need. 
The xa-connectionfalse/xa-connection 
is something that I have to do to have a WS MQ MDB working. I am not able to make the 
XA connection factory of WS MQ working. If I try to use it, the MDB never 
receives any messages, I am not sure to know why yet. Any suggestions at what I 
might need to look at? The MDB gets deployed without any errors; my client 
application is sending the message fine (I can see them in the WSMQ queue 
through the WSMQ admin tool), but the MDB never receives them. I think 
something wrong is happening because JBoss does not shutdown properly after that. 
It hangs in the stopping of the MDB, I

RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread thomas . cherel
Title: Message









Thanks for the extra information. I appreciate.



Thomas



-Original Message-
From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 09, 2003 10:19
AM
To:
[EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ





A while back I had it
working in WebLogic 6 with JTS transaction (NOT XA transactions). At least I
think it was JTS transactions. Essential you set the transactional flag to true
when creating a session, and have to do session.commit for your writes to appear.
This works in WLS 6.1 sp 4 onwards using their MessagingBridge (they will tell
you they back-ported the MessagingBridge to sp2 or sp3. They only did half a
job - it only works from sp4), or WLS7. In WLS7, I think MDBs have properties
which allow you to connect them to any JNDI tree using a URL and Context
Factory. In this case, you use the Sun FileSystem JNDI implementation and IBM's
jmsadmin (???) tool to manage the FileSystem JNDI. There are plenty of papers
on the web about doing this.











Good luck!











Dan.









-- 

Danny Yates





-Original
Message-
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: 09 June 2003 14:52
To:
[EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ

WebLogic is one of my
options as well.

Does it mean that you
managed to have a MQ JMS provider working within WebLogic (including having
Message Driven Bean deployed listening to MQ queues/topics) with XA/JTS
support?

If yes, I am interested
to know which version of WebLogic you are using and any kind of information you
can share on setting this up in WebLogic (I do not have too much experience
with WebLogic, but I was going to try that, at some point).



Thomas 



-Original Message-
From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 09, 2003 8:36
AM
To:
[EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ





I'm
afraid I never tried MQ with JBoss at all (XA or otherwise). We were using
WebLogic and doing JTS transactions in client mode against a remote MQ server.









-- 

Danny Yates





-Original
Message-
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: 09 June 2003 13:11
To:
[EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ

Thanks for the information. I went through this pain
already until I discovered that with MQ 5.3, service pack 3 (CSD03) and what IBM
is calling the Extended Transaction Client, you are now supposed to be able to
make XA work with the 'client mode' of the MQ JMS API (and this is what I am
currently trying).

Did you manage to make XA work with MQ 5.2 binding mode
and JBoss? I tried that as well with MQ 5.3 and I get the same problem as I
currently have, the MDB is not receiving any messages.

If you have a configuration which is working, I am
interested, if possible, to get some details. 

Thanks 

Thomas 

-Original Message- 
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]

Sent: Monday, June 09, 2003 3:47 AM

To:
[EMAIL PROTECTED] 
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ 

In MQSeries 5.2, you could only use the
XAConnectionFactory if you 
configured the MQSeries JMS API to
use 'bindings mode' instead of 
'client mode'. The upshot of this
is that the MQSeries Queue Manager 
and your Application Server needed
to be on the same box, because 
bindings mode uses shared memory to
communicate. 

Rgds, 

Dan. 

-- 
Danny Yates 
 



-Original Message- 
From:
[EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED]]

Sent: 08 June 2003 08:07

To:
[EMAIL PROTECTED] 
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ 



Thanks for the reply. 
I am working on a complete readme
to configure WebSphere MQ in JBoss. 
I will submit it as a patch once I
am done, no problem. 

I am not sure to understand what you are referring to
when talking about 
JNDI. If this is about bringing the
WebSphere MQ queue/topic and connection 
factory object in the JBoss
namespace, I actually wrote my own custom 
MBeans, wrapped them in a sar file
and deploy it. The nice thing about it is 
that I have a jboss-service.xml in
the sar which is similar to the 
jbossmq-destinations file and which
allows me to declare as many WSMQ object 
as I need. 

The xa-connectionfalse/xa-connection
is something that I have to do to 
have a WS MQ MDB working. I am not
able to make the XA connection factory of 
WS MQ working. If I try to use it,
the MDB never receives any messages, I am 
not sure to know why yet. Any
suggestions at what I might need to look at? 
The MDB gets deployed without any
errors; my client application is sending 
the message fine (I can see them in
the WSMQ queue through the WSMQ admin 
tool), but the MDB never receives
them. I think something wrong is happening 
because JBoss does not shutdown
properly after that. It hangs in the 
stopping of the MDB, I think.


I

RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread Danny . Yates
Title: Message



A 
while back I had it working in WebLogic 6 with JTS transaction (NOT XA 
transactions). At least I think it was JTS transactions. Essential you set the 
transactional flag to true when creating a session, and have to do 
session.commit for your writes to appear. This works in WLS 6.1 sp 4 onwards 
using their MessagingBridge (they will tell you they back-ported the 
MessagingBridge to sp2 or sp3. They only did half a job - it only works from 
sp4), or WLS7. In WLS7, I think MDBs have properties which allow you to connect 
them to any JNDI tree using a URL and Context Factory. In this case, you use the 
Sun FileSystem JNDI implementation and IBM's jmsadmin (???) tool to manage the 
FileSystem JNDI. There are plenty of papers on the web about doing 
this.

Good 
luck!

Dan.

-- 
Danny Yates


  
  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] Sent: 09 June 2003 
  14:52To: [EMAIL PROTECTED]Subject: RE: 
  [JBoss-user] JBoss XA transaction with WebSphere MQ
  
  WebLogic is one of my 
  options as well.
  Does it mean that you 
  managed to have a MQ JMS provider working within WebLogic (including having 
  Message Driven Bean deployed listening to MQ queues/topics) with XA/JTS 
  support?
  If yes, I am 
  interested to know which version of WebLogic you are using and any kind of 
  information you can share on setting this up in WebLogic (I do not have too 
  much experience with WebLogic, but I was going to try that, at some 
  point).
  
  Thomas 
  
  
  -Original 
  Message-From: 
  [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
  Sent: Monday, June 09, 2003 
  8:36 AMTo: 
  [EMAIL PROTECTED]Subject: RE: [JBoss-user] JBoss XA 
  transaction with WebSphere MQ
  
  
  I'm 
  afraid I never tried MQ with JBoss at all (XA or otherwise). We were using 
  WebLogic and doing JTS transactions in client mode against a remote MQ 
  server.
  
  
  -- 
  Danny Yates
  
  
-Original 
Message-From: 
[EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED] Sent: 09 June 2003 13:11To: 
[EMAIL PROTECTED]Subject: RE: [JBoss-user] JBoss XA 
transaction with WebSphere MQ
Thanks for the information. I went through this pain 
already until I discovered that with MQ 5.3, service pack 3 (CSD03) and what 
IBM is calling the Extended Transaction Client, you are now supposed to be 
able to make XA work with the 'client mode' of the MQ JMS API (and this is 
what I am currently trying).
Did you manage to make XA work with MQ 5.2 binding 
mode and JBoss? I tried that as well with MQ 5.3 and I get the same problem 
as I currently have, the MDB is not receiving any 
messages.
If you have a configuration which is working, I am 
interested, if possible, to get some details. 
Thanks 
Thomas 




_ 

Notice to recipient: 

The information in this internet e-mail and any attachments is confidential and may be privileged. It is intended solely for the addressee. If you are not the intended addressee please notify the sender immediately by telephone. If you are not the intended recipient, any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it, is prohibited and may be unlawful. 


When addressed to external clients any opinions or advice contained in this internet e-mail are subject to the terms and conditions expressed in any applicable governing terms of business or client engagement letter issued by the pertinent Bank of America group entity. 


If this email originates from the U.K. please note that Bank of America, N.A., London Branch, Banc of America Securities Limited and Banc of America Futures Incorporated are regulated by the Financial Services Authority.

_ 




RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-09 Thread thomas . cherel
Title: Message









Thanks for the extra information. I
appreciate.



Thomas



-Original Message-
From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Monday, June
 09, 2003 10:19 AM
To:
[EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA
transaction with WebSphere MQ





A while back I had it
working in WebLogic 6 with JTS transaction (NOT XA transactions). At least I
think it was JTS transactions. Essential you set the transactional flag to true
when creating a session, and have to do session.commit for your writes to appear.
This works in WLS 6.1 sp 4 onwards using their MessagingBridge (they will tell
you they back-ported the MessagingBridge to sp2 or sp3. They only did half a
job - it only works from sp4), or WLS7. In WLS7, I think MDBs have properties
which allow you to connect them to any JNDI tree using a URL and Context
Factory. In this case, you use the Sun FileSystem JNDI implementation and IBM's
jmsadmin (???) tool to manage the FileSystem JNDI. There are plenty of papers
on the web about doing this.











Good luck!











Dan.























_ 

Notice to recipient: 

The information in this internet e-mail and any attachments is confidential and may be privileged. It is intended solely for the addressee. If you are not the intended addressee please notify the sender immediately by telephone. If you are not the intended recipient, any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it, is prohibited and may be unlawful. 


When addressed to external clients any opinions or advice contained in this internet e-mail are subject to the terms and conditions expressed in any applicable governing terms of business or client engagement letter issued by the pertinent Bank of America group entity. 


If this email originates from the U.K. please note that Bank of America, N.A., London Branch, Banc of America Securities Limited and Banc of America Futures Incorporated are regulated by the Financial Services Authority.

_ 



RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

2003-06-08 Thread thomas . cherel
Thanks for the reply.
I am working on a complete readme to configure WebSphere MQ in JBoss.
I will submit it as a patch once I am done, no problem.

I am not sure to understand what you are referring to when talking about
JNDI. If this is about bringing the WebSphere MQ queue/topic and connection
factory object in the JBoss namespace, I actually wrote my own custom
MBeans, wrapped them in a sar file and deploy it. The nice thing about it is
that I have a jboss-service.xml in the sar which is similar to the
jbossmq-destinations file and which allows me to declare as many WSMQ object
as I need.

The xa-connectionfalse/xa-connection is something that I have to do to
have a WS MQ MDB working. I am not able to make the XA connection factory of
WS MQ working. If I try to use it, the MDB never receives any messages, I am
not sure to know why yet. Any suggestions at what I might need to look at?
The MDB gets deployed without any errors; my client application is sending
the message fine (I can see them in the WSMQ queue through the WSMQ admin
tool), but the MDB never receives them. I think something wrong is happening
because JBoss does not shutdown properly after that. It hangs in the
stopping of the MDB, I think.

I managed to create a new JMS resource adapter as you suggested. It seems to
work fine. I need to check if I can send a message to a JBoss and a WSMQ
queue using my two resource adapters but all in one transaction.
I did experience some problems if I change the following value in my new JMS
resource adapter: 
adapter-display-nameJMS Adapter/adapter-display-name
If it is not set to JMS Adapter, then JBoss complains about the deployment
being incomplete because of some dependencies with ConnectionManager and
pool (or something like that. I can try to find the exact message if
needed). Any ideas why?

Thanks again for the help.

Thomas



-Original Message-
From: Adrian Brock [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 06, 2003 8:07 AM
To: [EMAIL PROTECTED]
Subject: RE: [JBoss-user] JBoss XA transaction with WebSphere MQ

Hi Thomas,

Sounds like you have it nearly correct.

If you can post the working configuration as
a patch at www.sf.net/projects/jboss
I will include them in docs/examples/jms,
I don't have MQSeries so I can't test it.

For JNDI you have three options. 
1) Bind the external context into jboss's jndi
2  Use the following attribute in the provider config
attribute name=ProviderUrlwhatever/ProviderUrl
3) Write your own provider adapter

Re: xa-connectionfalse/xa-connection
You will need to specify this when the connection factory
you chose in the JMS provider is not an XAConnectionFactory.

Re: JMS resource adapter
You don't need to change ra.xml, these are just default values.

If you want a new JMS resource adapter, you should make a
new configuration (just like when you make a new data source).
You can specify the provider adapter as a property on the
connection manager.

3.2 style - 3.0 is too long winded :-) 
but the idea is the same.

  !-- JMS XA Resource adapter, use this to get transacted JMS in beans
--
  tx-connection-factory
jndi-nameMQJmsXA/jndi-name
xa-transaction/
adapter-display-nameMQ JMS Adapter/adapter-display-name
config-property name=JmsProviderAdapterJNDI
type=java.lang.Stringjava:MQJMSProvider/config-property
config-property name=SessionDefaultType
type=java.lang.Stringjavax.jms.Topic/config-property
 
security-domain-and-applicationJmsXARealm/security-domain-and-applica
tion
  /tx-connection-factory

Regards,
Adrian


Adrian Brock
Director of Support
Back Office
JBoss Group, LLC

  
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: 06 June 2003 05:59
To: [EMAIL PROTECTED]
Subject: [JBoss-user] JBoss XA transaction with WebSphere MQ




I have been playing with JBoss 3.0.5 and WebSphere MQ 5.3 (ex-MQSeries)
for a while now. 
I managed to create a new JMS provider in JBoss for WebSphere MQ: 
In jms-service.xml, duplicate the org.jboss.jms.jndi.JMSProviderLoader
mbean. Change the ProviderName to WebSphereMQJMSProvider, change the
QueueFactoryRef to WSMQConnectionFactory (I also changed the
TopicFactoryRef to WSMQConnectionFactory, but I did not play with
topics). I am passing the details on how to add the
WSMQConnectionFactory to the JBoss JNDI space.
I managed to create a new configuration for MDB listening to WS MQ: 
In standardjboss.xml, duplicate the Standard Message Driven Bean
container configuration. Change the name Standard Message Driven Bean to
WebSphere MQ Message Driven Bean and set the JMSProviderAdapterJNDI to
WebSphereMQJMSProvider (same as ProviderName in jms-service.xml).
After that, I can have two types of MDBs. One listening to a JBoss queue
and one listening to WS MQ queue. 
My ultimate goal is to have an MDB listening to a queue X and forward
each received messages to a queue Y. 
I want X to be a JBoss