users@genericjmsra.java.net

Re: genericjmsra - following up [Re: [Re: MQ Series and AS8] (or Weblogic9)]

From: Binod <Binod.Pg_at_Sun.COM>
Date: Tue, 03 Jan 2006 08:54:15 +0530

Hi Max,

Can you please increase the log level (please look at userguide and
LogLevel property) of RA to finest and post/examine the
log? Also, I assume that you have extended transaction client installed.

> Hi Binod
>
> Yes, I tried but could not define jms/wmqQCF in WMQ JMSADMIN, i.e. def
> xaqcf(jms/wmqQCF) could not define anything instead WMQ JMS context.
>
> But even after I changed the jms/wmqQCF to wmqQCF, I got same error as
> before, so I think that may not be relevant.
>
> Further I discovered the following after I configured. Any idea?
>
> <connector-connection-pool
> connection-definition-name="javax.jms.XAQueueConnectionFactory"
> fail-all-connections="false" idle-timeout-in-seconds="300"
> max-pool-size="32" max-wait-time-in-millis="60000"
> name="jms/wmqQCFPool" pool-resize-quantity="2"
> resource-adapter-name="genericra" steady-pool-size="8">
> <property name="ConnectionFactoryJndiName" value="wmqQCF"/>
> </connector-connection-pool>


You can not specify the connection-definition-name as
XAQueueConnectionFacrtory. Connection definition name is the type of the
connection factory that you look up
from the application. That will always be non-XA versions.

thanks,
Binod.

>
> *server log*
>
> [#|2006-01-03T10:55:05.613+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.core.classloading|_ThreadID=10;|LDR5010:
> All ejb(s) of [__ejb_container_timer_app] loaded successfully!|#]
>
> [#|2006-01-03T10:55:06.845+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.core|_ThreadID=10;|CORE5039:
> Resource named jms/wmqQCFPool [Type: connector-connection-pool] is
> disabled. It was not loaded.|#]
>
> [#|2006-01-03T10:55:06.865+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.core|_ThreadID=10;|CORE5039:
> Resource named jms/wmqTCFPool [Type: connector-connection-pool] is
> disabled. It was not loaded.|#]
>
> [#|2006-01-03T10:55:07.145+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.container.ejb|_ThreadID=10;|Instantiated
> container for: ejbName: GreeterBean; containerId: 73669296439689216|#]
>
> [#|2006-01-03T10:55:07.245+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.admin.server.mbeans|_ThreadID=10;|Deferring
> registration for
> "com.sun.appserv:standalone-ejb-module=greeter-EJBModule,name=bean-pool,type=bean-pool,category=monitor,ejb=GreeterBean,server=server"|#]
>
> [#|2006-01-03T10:55:07.305+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.core.classloading|_ThreadID=10;|LDR5010:
> All ejb(s) of [greeter-EJBModule] loaded successfully!|#]
>
> [#|2006-01-03T10:55:07.616+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.container.web|_ThreadID=10;|WEB0100:
> Loading web module [clusterjsp:clusterjsp.war] in virtual server
> [server] at [/clusterjsp]|#]
>
> [#|2006-01-03T10:55:08.357+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.container.ejb|_ThreadID=10;|Instantiated
> container for: ejbName: SimpleMessageEJB; containerId:
> 74262715091320832|#]
>
> [#|2006-01-03T10:55:08.447+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.admin.server.mbeans|_ThreadID=10;|Deferring
> registration for
> "com.sun.appserv:application=mdb-simple,name=bean-pool,type=bean-pool,category=monitor,ejb-module=mdb-simpleEjb_jar,ejb=SimpleMessageEJB,server=server"|#]
>
> [#|2006-01-03T10:55:08.848+0800|WARNING|sun-appserver-pe8.1_02|javax.enterprise.system.stream.err|_ThreadID=10;|javax.resource.ResourceException:
> SupportsXA is configured to true , but ConnectionFactory configured is
> not XA capable.
> at
> com.sun.genericra.inbound.EndpointConsumer.validate(EndpointConsumer.java:212)
> at
> com.sun.genericra.inbound.EndpointConsumer.initialize(EndpointConsumer.java:117)
> at
> com.sun.genericra.inbound.EndpointConsumer.start(EndpointConsumer.java:112)
> at
> com.sun.genericra.GenericJMSRA.endpointActivation(GenericJMSRA.java:97)
> at
> com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:221)
> at
> com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:187)
> at
> com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:221)
> at
> com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:477)
> at
> com.sun.enterprise.server.ApplicationLoader.load(ApplicationLoader.java:125)
> at
> com.sun.enterprise.server.TomcatApplicationLoader.load(TomcatApplicationLoader.java:95)
> at
> com.sun.enterprise.server.AbstractManager.load(AbstractManager.java:180)
> at
> com.sun.enterprise.server.ApplicationLifecycle.onStartup(ApplicationLifecycle.java:200)
> at
> com.sun.enterprise.server.ApplicationServer.onStartup(ApplicationServer.java:300)
> at com.sun.enterprise.server.PEMain.run(PEMain.java:294)
> at com.sun.enterprise.server.PEMain.main(PEMain.java:220)
> |#]
>
>
> Binod wrote:
>
>> Hi Max,
>>
>> Your activation config (in sun-ejb-jar.xml) seems to point to
>> jms/wmqQCF.
>> At the same time .bindings displays the name as just wmqQCF...
>> Shouldnt you provide just wmqQCF?
>>
>> - Binod.
>>
>>> Hi Binod
>>>
>>> I amended my -
>>>
>>> * appserver's domain.xml
>>> * genericra's sun-ejb-jar.xml
>>> * websphereMQ jmsadmin object definition of wmqQCF as
>>> com.ibm.mq.jms.MQXAConnectionFactory (jmsadmin.out)
>>>
>>> as zipped & attached.
>>>
>>> However, I'm still getting the following errors in server.log during
>>> start-up and cannot load the appserver sample mdb-simple sample apps.
>>>
>>> Appreciate any further input.
>>>
>>> Thanks
>>> Max
>>>
>>> [#|2006-01-03T00:52:34.682+0800|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.admin.server.mbeans|_ThreadID=10;|Deferring
>>> registration for
>>> "com.sun.appserv:application=mdb-simple,name=bean-pool,type=bean-pool,category=monitor,ejb-module=mdb-simpleEjb_jar,ejb=SimpleMessageEJB,server=server"|#]
>>>
>>>
>>> [#|2006-01-03T00:52:35.012+0800|WARNING|sun-appserver-pe8.1_02|javax.enterprise.system.stream.err|_ThreadID=10;|javax.resource.ResourceException:
>>> SupportsXA is configured to true , but ConnectionFactory configured
>>> is not XA capable.
>>> at
>>> com.sun.genericra.inbound.EndpointConsumer.validate(EndpointConsumer.java:212)
>>>
>>> at
>>> com.sun.genericra.inbound.EndpointConsumer.initialize(EndpointConsumer.java:117)
>>>
>>> at
>>> com.sun.genericra.inbound.EndpointConsumer.start(EndpointConsumer.java:112)
>>>
>>> at
>>> com.sun.genericra.GenericJMSRA.endpointActivation(GenericJMSRA.java:97)
>>> at
>>> com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:221)
>>>
>>> at
>>> com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:187)
>>>
>>> at
>>> com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:221)
>>>
>>> at
>>> com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:477)
>>>
>>> at
>>> com.sun.enterprise.server.ApplicationLoader.load(ApplicationLoader.java:125)
>>>
>>> at
>>> com.sun.enterprise.server.TomcatApplicationLoader.load(TomcatApplicationLoader.java:95)
>>>
>>> at
>>> com.sun.enterprise.server.AbstractManager.load(AbstractManager.java:180)
>>>
>>> at
>>> com.sun.enterprise.server.ApplicationLifecycle.onStartup(ApplicationLifecycle.java:200)
>>>
>>> at
>>> com.sun.enterprise.server.ApplicationServer.onStartup(ApplicationServer.java:300)
>>>
>>> at com.sun.enterprise.server.PEMain.run(PEMain.java:294)
>>> at com.sun.enterprise.server.PEMain.main(PEMain.java:220)
>>>
>>>
>>>
>>> Binod wrote:
>>>
>>>> Hi Max,
>>>>
>>>>> Hi Sushmita
>>>>>
>>>>> I see in your previously attached setup-ibmmq.sh
>>>>>
>>>>> * $apppath/bin/asadmin create-connector-connection-pool --raname
>>>>> genericra --connectiondefinition
>>>>> javax.jms.QueueConnectionFactory --transactionsupport
>>>>> NoTransaction --property ConnectionFactoryJndiName=XAQCF1
>>>>> qcpool
>>>>> * $apppath/bin/asadmin create-connector-resource --poolname
>>>>> qcpool
>>>>> jms/MyQueueConnectionFactory
>>>>> * $apppath/bin/asadmin create-connector-connection-pool --raname
>>>>> genericra --connectiondefinition
>>>>> javax.jms.TopicConnectionFactory --transactionsupport
>>>>> NoTransaction --property ConnectionFactoryJndiName=XATCF1
>>>>> tcpool
>>>>> * $apppath/bin/asadmin create-connector-resource --poolname
>>>>> tcpool
>>>>> jms/MyTopicConnectionFactory
>>>>>
>>>>> specifying in 'create-connector-connection-pool' -
>>>>>
>>>>> * --transactionsupport NoTransaction
>>>>> * --property ConnectionFactoryJndiName=XAQCF1
>>>>>
>>>>> Why are these needed? Especially I don't see XAQCF1 in the
>>>>> domain.xml, for
>>>>>
>>>>> * --property ConnectionFactoryJndiName=XAQCF1
>>>>>
>>>> This is the JNDI name bound by the WMQ's JMSAdmin command. The
>>>> resource adapter will lookup and use this resource internally from
>>>> WMQ's JNDI store.
>>>>
>>>>> Can I specify the following instead ?
>>>>> * --transactionsupport XATransaction
>>>>
>>>>
>>>> You can do that, as long as you can make sure that the connection
>>>> is being used within a transaction. If you are using the
>>>> connectionfactory from appclient, then there is no support for
>>>> transactions and you wouldnt want to set XATransaction as the
>>>> transactionsupport mode.
>>>>
>>>> - Binod.
>>>>
>>>>> Thanks
>>>>> Max
>>>>>
>>>>> Sushmita Sharma wrote:
>>>>>
>>>>>> Hi Max,
>>>>>> I've attached a sample sun-ejb-jar.xml for mdb and a
>>>>>> setup script which creates connector connection pool
>>>>>> and resources and resource adapter config in jndi
>>>>>> mode. Hope this will help.
>>>>>>
>>>>>> Summary of steps -
>>>>>> 1. Create queue manager, start queue manager, create queue conn
>>>>>> factory and queues in wmq
>>>>>> 2. In appserver, create resource adapter config and deploy
>>>>>> resource adapter
>>>>>> 3. Update server classpath for wmq classes
>>>>>> 4. Create connector-connection-pool, resource and admin object
>>>>>> 5. Add resource adapter config in mdb deployment descriptor
>>>>>>
>>>>>> Please refer to the attached files.
>>>>>>
>>>>>> Regards,
>>>>>> Sushmita.
>>>>>
>>>>>
>>
>>
>