users@glassfish.java.net

Re: SonicMQ 7.0 with Sun App Server 8.2

From: Ramesh Parthasarathy <Ramesh.Parthasarathy_at_Sun.COM>
Date: Thu, 22 Feb 2007 08:40:05 +0000

Hi Swapnil,

        

1. Could you also send me your admin-object (queue, jms/outqueue)
properties from domain.xml.
When you do a create-admin-object (for the queue) could you also provide
the JndiProperties in the --property option

asadmin create-admin-object --raname genericra --restype javax.jms.Topic
--property DestinationJndiName=outqueue
jms/outqueue:JndiProperties=java.naming.factory.initial\=
com.sonicsw.jndi.mfcontext.MFContextFactory,java.naming.provider.url\=tcp\://localhost\:2506,com.sonicsw.jndi.mfcontext.domain\=Domain1,
java.naming.security.principal\=Administrator,java.naming.security.credentials\=Administrator

This should fix the issue.

3. Just an observation, please remove LogLevel from the following
activation-config propery

<activation-config-property>
<activation-config-property-name>JndiProperties</activation-config-property-name>

<activation-config-property-value>java.naming.factory.initial=com.sonicsw.jndi.mfcontext.MFContextFactory,java.naming.provider.url=tcp://localhost:2506,com.sonicsw.jndi.mfcontext.domain=Domain1,java.naming.security.principal=Administrator,java.naming.security.credentials=Administrator,LogLevel=FINEST</activation-config-property-value>

4. Also output of "$AS_HOME/bin/asadmin version -v"

Thanks
-Ramesh



glassfish_at_javadesktop.org wrote On 02/22/07 06:31,:
> Hi Ramesh,
>
> Thanks for your inputs. I have done the following changes to successfully deploy MDB to listen to incoming messages -
>
> <activation-config-property>
> <activation-config-property-name>SupportsXA</activation-config-property-name>
> <activation-config-property-value>true</activation-config-property-value>
> </activation-config-property>
> <activation-config-property>
> <activation-config-property-name>ProviderIntegrationMode</activation-config-property-name>
> <activation-config-property-value>jndi</activation-config-property-value>
> </activation-config-property>
> <activation-config-property>
> <activation-config-property-name>JndiProperties</activation-config-property-name>
> <activation-config-property-value>java.naming.factory.initial=com.sonicsw.jndi.mfcontext.MFContextFactory,java.naming.provider.url=tcp://localhost:2506,com.sonicsw.jndi.mfcontext.domain=Domain1,java.naming.security.principal=Administrator,java.naming.security.credentials=Administrator,LogLevel=FINEST</activation-config-property-value>
> </activation-config-property>
> <activation-config-property>
> <activation-config-property-name>XAQueueConnectionFactoryClassName</activation-config-property-name>
> <activation-config-property-value>progress.message.jclient.xa.XAQueueConnectionFactory</activation-config-property-value>
> </activation-config-property>
> <activation-config-property>
> <activation-config-property-name>UserName</activation-config-property-name>
> <activation-config-property-value>XYZ</activation-config-property-value>
> </activation-config-property>
> <activation-config-property>
> <activation-config-property-name>Password</activation-config-property-name>
> <activation-config-property-value>ABCD</activation-config-property-value>
> </activation-config-property>
>
> Now I am facing issue while sending the message on outqueue from MDB. I have the following code in ejbCreate -
>
> public void ejbCreate() {
> System.out.println("In VoteMessageBean.ejbCreate()");
> try {
> Context jndiContext = new InitialContext();
> queueConnectionFactory = (QueueConnectionFactory)
> jndiContext.lookup("java:comp/env/jms/outboundXAQCF");
>
> System.out.println(" queueConnectionFactory1 " + queueConnectionFactory);
> System.out.println(" queueConnectionFactory2 " + queueConnectionFactory.getClass());
>
> queue = (Queue)jndiContext.lookup("java:comp/env/jms/outqueue");
>
> System.out.println(" queue0 " + queue);
> System.out.println(" queue1 " + queue.getQueueName());
> System.out.println(" queue2 " + queue.getClass());
>
> } catch (Exception e) {
> System.out.println("MESSAGEBEAN.ejbcreate() got Exception "+ e.getMessage());
> e.printStackTrace();
> }
> }
>
> Below is the relevant server.log output -
>
>
> [#|2007-02-22T00:11:52.107-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=53;|
> In VoteMessageBean.ejbCreate()|#]
>
> [#|2007-02-22T00:11:52.107-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=57;|
> In VoteMessageBean.VoteMessageBean()|#]
>
> [#|2007-02-22T00:11:52.107-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=57;|
> In VoteMessageBean.setMessageDrivenContext()|#]
>
> [#|2007-02-22T00:11:52.107-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=57;|
> In VoteMessageBean.ejbCreate()|#]
>
> [#|2007-02-22T00:11:52.122-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=57;|
> queueConnectionFactory1 com.sun.genericra.outbound.ConnectionFactory_at_1ad71f0|#]
>
> [#|2007-02-22T00:11:52.122-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=57;|
> queueConnectionFactory2 class com.sun.genericra.outbound.ConnectionFactory|#]
>
> [#|2007-02-22T00:11:52.122-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=57;|
> queue0 com.sun.genericra.outbound.QueueProxy_at_7ca58b69{ConnectionFactoryClassName = null},{QueueConnectionFactoryClassName = null},{TopicConnectionFactoryClassName = null},{XAConnectionFactoryClassName = null},{XAQueueConnectionFactoryClassName = null},{XATopicConnectionFactoryClassName = null},{QueueClassName = null},{TopicClassName = null},{UnifiedDestinationClassName = null},{ConnectionFactoryProperties = null},{JndiProperties = null},{ProviderIntegrationMode = null},{CommonSetterMethodName = null},{SupportsXA = false},|#]
>
> [#|2007-02-22T00:11:52.122-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=57;|
> MESSAGEBEAN.ejbcreate() got Exception null|#]
>
> [#|2007-02-22T00:11:52.122-0600|WARNING|sun-appserver-pe8.2|javax.enterprise.system.stream.err|_ThreadID=57;|
> java.lang.NullPointerException
> at com.sun.genericra.outbound.DestinationAdapter.initialize(DestinationAdapter.java:105)
> at com.sun.genericra.outbound.DestinationAdapter._getPhysicalDestination(DestinationAdapter.java:74)
> at com.sun.genericra.outbound.QueueProxy.getQueueName(QueueProxy.java:28)
> at com.motorola.gama.ejb.mdb.VoteMessageBean.ejbCreate(VoteMessageBean.java:88)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at com.sun.ejb.containers.MessageBeanContainer.createMessageDrivenEJB(MessageBeanContainer.java:692)
> at com.sun.ejb.containers.MessageBeanContainer.access$100(MessageBeanContainer.java:71)
> at com.sun.ejb.containers.MessageBeanContainer$MessageBeanContextFactory.create(MessageBeanContainer.java:467)
> at com.sun.ejb.containers.util.pool.NonBlockingPool.preload(NonBlockingPool.java:249)
> at com.sun.ejb.containers.util.pool.NonBlockingPool.doResize(NonBlockingPool.java:473)
> at com.sun.ejb.containers.util.pool.NonBlockingPool$ReSizeWork.run(NonBlockingPool.java:541)
> at com.sun.ejb.containers.util.pool.NonBlockingPool$ReSizeWork.service(NonBlockingPool.java:533)
> at com.sun.ejb.containers.util.WorkAdapter.doWork(WorkAdapter.java:44)
> at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:409)
> |#]
> [#|2007-02-22T00:11:52.122-0600|WARNING|sun-appserver-pe8.2|javax.enterprise.system.stream.err|_ThreadID=57;|
> java.lang.NullPointerException
> at com.sun.genericra.GenericJMSRAProperties.getSupportsXA(GenericJMSRAProperties.java:387)
> at com.sun.genericra.GenericJMSRAProperties.toString(GenericJMSRAProperties.java:707)
> at com.sun.genericra.outbound.DestinationAdapter.toString(DestinationAdapter.java:169)
> at java.lang.String.valueOf(String.java:2615)
> at java.lang.StringBuffer.append(StringBuffer.java:220)
> at com.motorola.gama.ejb.mdb.VoteMessageBean.ejbCreate(VoteMessageBean.java:87)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at com.sun.ejb.containers.MessageBeanContainer.createMessageDrivenEJB(MessageBeanContainer.java:692)
> at com.sun.ejb.containers.MessageBeanContainer.access$100(MessageBeanContainer.java:71)
> at com.sun.ejb.containers.MessageBeanContainer$MessageBeanContextFactory.create(MessageBeanContainer.java:467)
> at com.sun.ejb.containers.util.pool.NonBlockingPool.preload(NonBlockingPool.java:249)
> at com.sun.ejb.containers.util.pool.NonBlockingPool.doResize(NonBlockingPool.java:473)
> at com.sun.ejb.containers.util.pool.NonBlockingPool$ReSizeWork.run(NonBlockingPool.java:541)
> at com.sun.ejb.containers.util.pool.NonBlockingPool$ReSizeWork.service(NonBlockingPool.java:533)
> at com.sun.ejb.containers.util.WorkAdapter.doWork(WorkAdapter.java:44)
> at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:409)
> |#]
>
>
>
> I have also put in an explicit Sys out for ActivationSpec.toString and the output is below -
> [#|2007-02-22T00:11:48.982-0600|INFO|sun-appserver-pe8.2|javax.enterprise.system.stream.out|_ThreadID=56;|
> com.sun.genericra.inbound.ActivationSpec_at_5b48a726{ConnectionFactoryClassName = null},{QueueConnectionFactoryClassName = null},{TopicConnectionFactoryClassName = null},{XAConnectionFactoryClassName = null},{XAQueueConnectionFactoryClassName = progress.message.jclient.xa.XAQueueConnectionFactory},{XATopicConnectionFactoryClassName = null},{QueueClassName = null},{TopicClassName = null},{UnifiedDestinationClassName = null},{ConnectionFactoryProperties = null},{JndiProperties = java.naming.factory.initial=com.sonicsw.jndi.mfcontext.MFContextFactory,java.naming.provider.url=tcp://localhost:2506,com.sonicsw.jndi.mfcontext.domain=Domain1,java.naming.security.principal=Administrator,java.naming.security.credentials=Administrator,LogLevel=FINEST},{ProviderIntegrationMode = jndi},{CommonSetterMethodName = null},{SupportsXA = true},{RedeliveryInterval = 1},{RedeliveryAttempts = 3},{ClientID = null},{MessageSelector = null},{SubscriptionDurability = Non-Durable},{ConnectionFactoryJNDIN
ame = inboundXAQCF},{SubscriptionName = null},{DestinationJNDIName = inqueue},{DestinationType = javax.jms.Queue},{DeadMessageDestinationType = javax.jms.Queue},{MaxPoolSize = 30},{DestinationProperties = null},{DeadMessageDestinationJndiName = deadmsgqueue},{DeadMessageConnectionFactoryJndiName = outboundXAQCF},{DeadMessageConnectionFactoryProperties = null},{DeadMessageDestinationClassName = null},{DeadMessageDestinationProperties = null},{SendBadMessagesToDMD = true},{EndpointReleaseTimeOut = 30},{InstanceCount = 1},{LoadBalancingRequired = true},{Instance ID = 0},{CustomLoadBalancingMessageSelector = },{ShareClientID = false}|#]
>
> I am working with a restriction that I can not upgrade the AppServer version. Let me know if there is a fix available for 8.x version.
>
> Thanks!
> Swapnil
> [Message sent by forum member 'sharmaswapnil' (sharmaswapnil)]
>
> http://forums.java.net/jive/thread.jspa?messageID=204771
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>