[JCA/JBoss] - Configuring JCA 1.5 jms-ra.rar for WSMQ
by mvilot
Looks like the published code is incorrect.
Configuration: jboss-4.0.4.GA with WSMQ 6.0, both running on Windoze. JBoss installer summary: Chosen installation packsjmx-core
| minimal
| binding-service
| client-deployer-service
| dynclassloader-service.xml
| ear-deployer
| ejb-timer-service
| ejb-deployer
| hsqldb-ds
| jboss-local-jdbc.rar
| javamail
| jbossretro
| jbossws14
| jca-service
| jdbc-metadata-service
| jbossmq-service
| jms-asf-rar
| jms-injvm-invoker
| jms-socket-invoker
| jmx-console
| invokers-service
| jmx-invoker-service
| jta-service
| usertx-service
| mail-inflow-adaptor
| naming
| security
| war-deployer
| jboss-remoting
|
| Configured the -ds.xml per http://wiki.jboss.org/wiki/Wiki.jsp?page=IntegrationWithWebSphereMQSeries
| Compiled and deployed the .sar:INFO [ResponseQueue] Bound to JNDI name: queue/ResponseQueue
| | INFO [RequestQueue] Bound to JNDI name: queue/RequestQueue
| | INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=ConnectionFactoryBinding
| | ,name=WSMQJms' to JNDI name 'java:WSMQJms'
| From the jmx-console, JNDIView 1st throws the following exception chain (no HA or EJB cache-invalidation-service support in this configuration):
| ERROR [JNDIView] JNDIView.getHAJndiAttributes() failed
| | java.lang.NullPointerException: name cannot be null
| | at javax.management.ObjectName.construct(ObjectName.java:342)
| | at javax.management.ObjectName.<init>(ObjectName.java:1304)
| | at org.jboss.naming.JNDIView.getHAJndiAttributes(JNDIView.java:836)
| | at org.jboss.naming.JNDIView.getHAUrl(JNDIView.java:811)
| | at org.jboss.naming.JNDIView.list(JNDIView.java:193)
| | 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 org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
| | at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
| | at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
| | at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
| | at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
| | at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
| | at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
| | at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| | at org.jboss.jmx.adaptor.control.Server.invokeOpByName(Server.java:258)
| | at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.invokeOpByName(HtmlAdaptorServlet.java:287)
| | at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.processRequest(HtmlAdaptorServlet.java:102)
| | at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.doGet(HtmlAdaptorServlet.java:77)
| | at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
| | at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
| | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
| | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| | at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| | at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
| | at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
| | at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
| | at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
| | at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| | at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| | at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| | at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| | at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
| | at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java
| | :664)
| | at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| | at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| | at java.lang.Thread.run(Thread.java:595)
| (An annoyance that should be fixed), then displays a reasonable JNDI tree:
| java: Namespace
| | +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| | +- DefaultDS (class: org.jboss.resource.adapter.jdbc.WrapperDataSource)
| | +- SecurityProxyFactory (class: org.jboss.security.SubjectSecurityProxyFactory)
| | +- WSMQJms (class: org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl)
| | +- DefaultJMSProvider (class: org.jboss.jms.jndi.JNDIProviderAdapter)
| | +- WSMQJMSProvider (class: org.jboss.jms.jndi.JNDIProviderAdapter)
| | +- comp (class: javax.naming.Context)
| | +- JmsXA (class: org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl)
| | +- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| | +- jaas (class: javax.naming.Context)
| | | +- other (class: org.jboss.security.plugins.SecurityDomainContext)
| | | +- HsqlDbRealm (class: org.jboss.security.plugins.SecurityDomainContext)
| | | +- jbossmq (class: org.jboss.security.plugins.SecurityDomainContext)
| | | +- JmsXARealm (class: org.jboss.security.plugins.SecurityDomainContext)
| | +- timedCacheFactory (class: javax.naming.Context)
| | Failed to lookup: timedCacheFactory, errmsg=org.jboss.util.TimedCachePolicy
| | +- TransactionPropagationContextExporter (class: org.jboss.tm.TransactionPropagationContextFactory)
| | +- StdJMSPool (class: org.jboss.jms.asf.StdServerSessionPoolFactory)
| | +- TransactionPropagationContextImporter (class: org.jboss.tm.TransactionPropagationContextImporter)
| | +- TransactionManager (class: org.jboss.tm.TxManager)
| |
| | Global JNDI Namespace
| | +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| | +- WSMQQueueConnectionFactory (class: com.ibm.mq.jms.MQQueueConnectionFactory)
| | +- wsmq (class: org.jnp.interfaces.NamingContext)
| | | +- ResponseQueue (class: com.ibm.mq.jms.MQQueue)
| | | +- RequestQueue (class: com.ibm.mq.jms.MQQueue)
| | +- TopicConnectionFactory (class: org.jboss.naming.LinkRefPair)
| | +- EventDispatcher (class: org.jboss.ws.eventing.mgmt.DispatcherDelegate)
| | +- UserTransactionSessionFactory (proxy: $Proxy35 implements interface org.jboss.tm.usertx.interfaces.UserTransactionSessionFactory)
| | +- UIL2ConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
| | +- UIL2XAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| | +- QueueConnectionFactory (class: org.jboss.naming.LinkRefPair)
| | +- queue (class: org.jnp.interfaces.NamingContext)
| | | +- ResponseQueue (class: org.jboss.mq.SpyQueue)
| | | +- RequestQueue (class: org.jboss.mq.SpyQueue)
| | | +- DLQ (class: org.jboss.mq.SpyQueue)
| | +- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| | +- UserTransaction (class: org.jboss.tm.usertx.client.ClientUserTransaction)
| | +- jmx (class: org.jnp.interfaces.NamingContext)
| | | +- invoker (class: org.jnp.interfaces.NamingContext)
| | | | +- RMIAdaptor (proxy: $Proxy29 implements interface org.jboss.jmx.adaptor.rmi.RMIAdaptor,interface org.jboss.jmx.adaptor.rmi.RMIAdaptorExt)
| | | +- rmi (class: org.jnp.interfaces.NamingContext)
| | | | +- RMIAdaptor[link -> jmx/invoker/RMIAdaptor] (class: javax.naming.LinkRef)
| | +- UILXAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| | +- UILConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
| Now, here's the fun part. Deploying the MDB provokes the following:
| INFO [EjbModule] Deploying WSMQMDB
| | WARN [JMSContainerInvoker] JMS provider failure detected for WSMQMDB
| | org.jboss.deployment.DeploymentException: Error during queue setup; - nested throwable: (java.lang.ClassCastException: o
| | rg.jboss.resource.adapter.jms.JmsConnectionFactoryImpl)
| | at org.jboss.deployment.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:53)
| | at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:811)
| | at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:839)
| | ...
| The key settings are in the -ds.xml <connection-factories> tag: <mbean code="org.jboss.jms.jndi.JMSProviderLoader"
| | name="jboss.mq:service=JMSProviderLoader,name=WSMQJMSProvider">
| | <attribute name="ProviderName">WSMQJMSProvider</attribute>
| | <attribute name="ProviderAdapterClass">org.jboss.jms.jndi.JNDIProviderAdapter</attribute>
| | <!-- The queue connection factory -->
| | <attribute name="QueueFactoryRef">WSMQQueueConnectionFactory</attribute>
| | <!-- The topic factory -->
| | <attribute name="TopicFactoryRef">WSMQTopicConnectionFactory</attribute>
| | </mbean>
| |
| | <no-tx-connection-factory>
| | <jndi-name>WSMQJms</jndi-name>
| | <rar-name>jms-ra.rar</rar-name> <!-- JCA 1.5 -->
| | <use-java-context>true</use-java-context>
| | <connection-definition>org.jboss.resource.adapter.jms.JmsConnectionFactory</connection-definition>
| | <!-- ClassCastException: org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl -->
| | <max-pool-size>20</max-pool-size>
| | <!-- These are JBoss-specific properties for a ManagedConnectionFactory -->
| | <!-- MUST MATCH Mbean JNDI NAME (overrides default "java:/DefaultJMSProvider") -->
| | <config-property name="JmsProviderAdapterJNDI" type="java.lang.String">WSMQJMSProvider</config-property>
| | <config-property name="SessionDefaultType" type="java.lang.String">javax.jms.Queue</config-property>
| | <config-property name="UserName" type="java.lang.String">User</config-property>
| | <config-property name="Password" type="java.lang.String">password</config-property>
| | </no-tx-connection-factory>
| Looks like the JmsConnectionFactoryImpl class _does_ exist in the jms-ra.jar deployed inside the jms-ra.rar.
|
| Any ideas why the ClassCastException is happening?
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966428#3966428
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966428
19 years, 8 months
[Installation, Configuration & Deployment] - Configure JBossAS to use IBM WSMQ
by mvilot
Looks like the published code is incorrect.
Configuration: jboss-4.0.4.GA with WSMQ 6.0, both running on Windoze. JBoss installer summary: Chosen installation packsjmx-core
| minimal
| binding-service
| client-deployer-service
| dynclassloader-service.xml
| ear-deployer
| ejb-timer-service
| ejb-deployer
| hsqldb-ds
| jboss-local-jdbc.rar
| javamail
| jbossretro
| jbossws14
| jca-service
| jdbc-metadata-service
| jbossmq-service
| jms-asf-rar
| jms-injvm-invoker
| jms-socket-invoker
| jmx-console
| invokers-service
| jmx-invoker-service
| jta-service
| usertx-service
| mail-inflow-adaptor
| naming
| security
| war-deployer
| jboss-remoting
|
| Configured the -ds.xml per http://wiki.jboss.org/wiki/Wiki.jsp?page=IntegrationWithWebSphereMQSeries
| Compiled and deployed the .sar:INFO [ResponseQueue] Bound to JNDI name: queue/ResponseQueue
| | INFO [RequestQueue] Bound to JNDI name: queue/RequestQueue
| | INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=ConnectionFactoryBinding
| | ,name=WSMQJms' to JNDI name 'java:WSMQJms'
| From the jmx-console, JNDIView 1st throws the following exception chain (no HA or EJB cache-invalidation-service support in this configuration):
| ERROR [JNDIView] JNDIView.getHAJndiAttributes() failed
| | java.lang.NullPointerException: name cannot be null
| | at javax.management.ObjectName.construct(ObjectName.java:342)
| | at javax.management.ObjectName.<init>(ObjectName.java:1304)
| | at org.jboss.naming.JNDIView.getHAJndiAttributes(JNDIView.java:836)
| | at org.jboss.naming.JNDIView.getHAUrl(JNDIView.java:811)
| | at org.jboss.naming.JNDIView.list(JNDIView.java:193)
| | 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 org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
| | at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
| | at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
| | at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
| | at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
| | at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
| | at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
| | at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| | at org.jboss.jmx.adaptor.control.Server.invokeOpByName(Server.java:258)
| | at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.invokeOpByName(HtmlAdaptorServlet.java:287)
| | at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.processRequest(HtmlAdaptorServlet.java:102)
| | at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.doGet(HtmlAdaptorServlet.java:77)
| | at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
| | at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
| | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
| | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| | at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| | at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
| | at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
| | at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
| | at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
| | at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| | at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| | at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| | at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| | at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
| | at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java
| | :664)
| | at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| | at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| | at java.lang.Thread.run(Thread.java:595)
| (An annoyance that should be fixed), then displays a reasonable JNDI tree:
| java: Namespace
| | +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| | +- DefaultDS (class: org.jboss.resource.adapter.jdbc.WrapperDataSource)
| | +- SecurityProxyFactory (class: org.jboss.security.SubjectSecurityProxyFactory)
| | +- WSMQJms (class: org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl)
| | +- DefaultJMSProvider (class: org.jboss.jms.jndi.JNDIProviderAdapter)
| | +- WSMQJMSProvider (class: org.jboss.jms.jndi.JNDIProviderAdapter)
| | +- comp (class: javax.naming.Context)
| | +- JmsXA (class: org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl)
| | +- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| | +- jaas (class: javax.naming.Context)
| | | +- other (class: org.jboss.security.plugins.SecurityDomainContext)
| | | +- HsqlDbRealm (class: org.jboss.security.plugins.SecurityDomainContext)
| | | +- jbossmq (class: org.jboss.security.plugins.SecurityDomainContext)
| | | +- JmsXARealm (class: org.jboss.security.plugins.SecurityDomainContext)
| | +- timedCacheFactory (class: javax.naming.Context)
| | Failed to lookup: timedCacheFactory, errmsg=org.jboss.util.TimedCachePolicy
| | +- TransactionPropagationContextExporter (class: org.jboss.tm.TransactionPropagationContextFactory)
| | +- StdJMSPool (class: org.jboss.jms.asf.StdServerSessionPoolFactory)
| | +- TransactionPropagationContextImporter (class: org.jboss.tm.TransactionPropagationContextImporter)
| | +- TransactionManager (class: org.jboss.tm.TxManager)
| |
| | Global JNDI Namespace
| | +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| | +- WSMQQueueConnectionFactory (class: com.ibm.mq.jms.MQQueueConnectionFactory)
| | +- wsmq (class: org.jnp.interfaces.NamingContext)
| | | +- ResponseQueue (class: com.ibm.mq.jms.MQQueue)
| | | +- RequestQueue (class: com.ibm.mq.jms.MQQueue)
| | +- TopicConnectionFactory (class: org.jboss.naming.LinkRefPair)
| | +- EventDispatcher (class: org.jboss.ws.eventing.mgmt.DispatcherDelegate)
| | +- UserTransactionSessionFactory (proxy: $Proxy35 implements interface org.jboss.tm.usertx.interfaces.UserTransactionSessionFactory)
| | +- UIL2ConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
| | +- UIL2XAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| | +- QueueConnectionFactory (class: org.jboss.naming.LinkRefPair)
| | +- queue (class: org.jnp.interfaces.NamingContext)
| | | +- ResponseQueue (class: org.jboss.mq.SpyQueue)
| | | +- RequestQueue (class: org.jboss.mq.SpyQueue)
| | | +- DLQ (class: org.jboss.mq.SpyQueue)
| | +- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| | +- UserTransaction (class: org.jboss.tm.usertx.client.ClientUserTransaction)
| | +- jmx (class: org.jnp.interfaces.NamingContext)
| | | +- invoker (class: org.jnp.interfaces.NamingContext)
| | | | +- RMIAdaptor (proxy: $Proxy29 implements interface org.jboss.jmx.adaptor.rmi.RMIAdaptor,interface org.jboss.jmx.adaptor.rmi.RMIAdaptorExt)
| | | +- rmi (class: org.jnp.interfaces.NamingContext)
| | | | +- RMIAdaptor[link -> jmx/invoker/RMIAdaptor] (class: javax.naming.LinkRef)
| | +- UILXAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| | +- UILConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
| Now, here's the fun part. Deploying the MDB provokes the following:
| INFO [EjbModule] Deploying WSMQMDB
| | WARN [JMSContainerInvoker] JMS provider failure detected for WSMQMDB
| | org.jboss.deployment.DeploymentException: Error during queue setup; - nested throwable: (java.lang.ClassCastException: o
| | rg.jboss.resource.adapter.jms.JmsConnectionFactoryImpl)
| | at org.jboss.deployment.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:53)
| | at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:811)
| | at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:839)
| | ...
| The key settings are in the -ds.xml <connection-factories> tag: <mbean code="org.jboss.jms.jndi.JMSProviderLoader"
| | name="jboss.mq:service=JMSProviderLoader,name=WSMQJMSProvider">
| | <attribute name="ProviderName">WSMQJMSProvider</attribute>
| | <attribute name="ProviderAdapterClass">org.jboss.jms.jndi.JNDIProviderAdapter</attribute>
| | <!-- The queue connection factory -->
| | <attribute name="QueueFactoryRef">WSMQQueueConnectionFactory</attribute>
| | <!-- The topic factory -->
| | <attribute name="TopicFactoryRef">WSMQTopicConnectionFactory</attribute>
| | </mbean>
| |
| | <no-tx-connection-factory>
| | <jndi-name>WSMQJms</jndi-name>
| | <rar-name>jms-ra.rar</rar-name> <!-- JCA 1.5 -->
| | <use-java-context>true</use-java-context>
| | <connection-definition>org.jboss.resource.adapter.jms.JmsConnectionFactory</connection-definition>
| | <!-- ClassCastException: org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl -->
| | <max-pool-size>20</max-pool-size>
| | <!-- These are JBoss-specific properties for a ManagedConnectionFactory -->
| | <!-- MUST MATCH Mbean JNDI NAME (overrides default "java:/DefaultJMSProvider") -->
| | <config-property name="JmsProviderAdapterJNDI" type="java.lang.String">WSMQJMSProvider</config-property>
| | <config-property name="SessionDefaultType" type="java.lang.String">javax.jms.Queue</config-property>
| | <config-property name="UserName" type="java.lang.String">User</config-property>
| | <config-property name="Password" type="java.lang.String">password</config-property>
| | </no-tx-connection-factory>
| Looks like the JmsConnectionFactoryImpl class _does_ exist in the jms-ra.jar deployed inside the jms-ra.rar.
|
| Any ideas why the ClassCastException is happening?
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966427#3966427
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966427
19 years, 8 months
[EJB 3.0] - Problem with User defined object in Jboss web service - "Can
by zohar_sap
Hi,
When I call a ws method - test1() - that gets a user defined object from a .Net client I get an exception on the client side:
"Cannot find child element: MyClass_1"} System.Web.Services.Protocols.SoapException {System.Web.Services.Protocols.SoapHeaderException}
I use jboss 4.0.4GA + Java 1.5.0_06-b05
Any ideas ?
Thanka
*Here are my classes:
public interface TestInterface extends Remote {
public String test1 (String a, MyClass b) throws RemoteException;
}
-------------------------------------------------------------------------
@Stateless
@WebService
@SOAPBinding(style = SOAPBinding.Style.RPC)
public class TestFacade implements TestFacadeInterface {
@WebMethod
public String test1 (String a, MyClass b) throws RemoteException{
return a;
}
}
-------------------------------------------------------------------------------
public class MyClass implements Serializable{
String a;
public String getA() {
return a;
}
public void setA(String a) {
this.a = a;
}
}
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966426#3966426
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966426
19 years, 8 months
[Management, JMX/JBoss] - JMX ServiceURL and Spring
by geirgp
Okay, spring and JMX again. I'm using Spring's serverConnector to serve my MBean's via JMX. This is done my adding the following lines to Spring's config
<bean id="serverConnector" class="org.springframework.jmx.support.ConnectorServerFactoryBean">
| <property name="serviceUrl" value="service:jmx:rmi://localhost:5544" />
| </bean>
This works very well and I can access all beans in JBoss' MBean server remotely. However the last part of the serviceUrl used to connect to this server is random ("service:jmx:rmi://localhost:5544/stub/***random***"). The serviceUrl changes everytime I deploy the application, so I have to change my client-application as well.
I've consulted the Spring forum which refered me to JBoss as Spring doesn't do anything but forward calls to the appropriate JMX implementation.
So the big question is if there is a way to set this serviceUrl manually, a way to look it up or maybe traverse through a list of serviceUrls. Any way works for me as long as I don't have to look it up manually and copy it into my client application everytime I redeploy or restart JBoss.
The serviceUrl looks like the following. For now i just use the JBoss JMX-console to look it up (serverConnector is registered as a MBean) and copy-paste into client application:
service:jmx:rmi://localhost:5544/stub/rO0ABXNyAC5qYXZheC5tYW5hZ2VtZW50LnJlbW90ZS5ybWkuUk1JU2VydmVySW1wbF9TdHViAAAAAAAAAAICAAB4cgAaamF2YS5ybWkuc2VydmVyLlJlbW90ZVN0dWLp/tzJi+FlGgIAAHhyABxqYXZhLnJtaS5zZXJ2ZXIuUmVtb3RlT2JqZWN002G0kQxhMx4DAAB4cHc3AAtVbmljYXN0UmVmMgAADDE3Mi4yNS4xMS4yOAAAFagAAAAAAAAAArBYvPsAAAENINmEZYAAAHg=
Any ideas? Thanks in advance.
Geir
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966419#3966419
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966419
19 years, 8 months