Exception on remote ServiceInvoker invocation
angeloimm Oct 3, 2013 7:21 AMHi there
I'm in this scenario: a web application running on an EAP 6.0.1 on server A and my SOAP 5.3 running on server B
From my web application on server A I need to remotely call the ServiceInvoker
By following the jboss programmer guide (JBoss_Enterprise_SOA_Platform-5-ESB_Programmers_Guide-en-US.pdf) I added in my web application classpath (that is WEB-INF/lib) the following jars:
- jboss-mdr.jar
- concurrent.jar
- scout-1.2.6.jar
- juddi-client-3.1.3.jar
- jbossesb-config-model.jar
- hornetq-core-client.jar
- commons-collections.jar
- jbossesb-registry.jar
- jbossjmx-ant.jar
- jboss-common-core.jar
- jbossesb-rosetta.jar
- jboss-messaging-client.jar
- trove.jar
- jboss-javaee.jar
- uddi-ws-3.1.3.jar
- jbossts-common.jar
- commons-lang-2.4.jar
- hornetq-jms.jar
- javassist.jar
- commons-logging.jar
- jboss-aop-client.jar
- netty.jar
- jboss-logging-spi.jar
- commons-configuration-1.5.jar
- jboss-remoting.jar
- commons-codec-1.3.jar
- serializer.jar
- jbossall-client.jar
Please note that I had to add also the following jars jboss-mdr.jar, jboss-messaging-client.jar and jboss-remoting.jar (though not indicated in the documentation) otherwise my web application couldn't be deployed
Always under my classpath (in WEB-INF/classes) I added the jbossesb-properties.xml file; this is its content:
<?xml version="1.0" encoding="ISO-8859-1"?> <esb xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="jbossesb-1_0.xsd"> <properties name="core"> <property name="org.jboss.soa.esb.jndi.server.context.factory" value="org.jnp.interfaces.NamingContextFactory"/> <property name="org.jboss.soa.esb.jndi.server.url" value="10.24.5.8:1099"/> <property name="org.jboss.soa.esb.persistence.connection.factory" value="org.jboss.internal.soa.esb.persistence.format.MessageStoreFactoryImpl"/> <property name="org.jboss.soa.esb.loadbalancer.policy" value="org.jboss.soa.esb.listeners.ha.RoundRobin"/> <property name="org.jboss.soa.esb.mime.text.types" value="text/*;application/xml;application/*+xml"/> <property name="jboss.esb.invm.scope.default" value="NONE"/> <property name="org.jboss.soa.esb.deployment.schema.validation" value="true"/> </properties> <properties name="security"> <property name="org.jboss.soa.esb.services.security.implementationClass" value="org.jboss.internal.soa.esb.services.security.JaasSecurityService"/> <property name="org.jboss.soa.esb.services.security.callbackHandler" value="org.jboss.internal.soa.esb.services.security.UserPassCallbackHandler"/> <property name="org.jboss.soa.esb.services.security.sealAlgorithm" value="TripleDES"/> <property name="org.jboss.soa.esb.services.security.sealKeySize" value="168"/> <property name="org.jboss.soa.esb.services.security.contextTimeout" value="30000"/> <property name="org.jboss.soa.esb.services.security.contextPropagatorImplementationClass" value="org.jboss.internal.soa.esb.services.security.JBossASContextPropagator"/> <property name="org.jboss.soa.esb.services.security.publicKeystore" value="/publicKeyStore"/> <property name="org.jboss.soa.esb.services.security.publicKeystorePassword" value="testKeystorePassword"/> <property name="org.jboss.soa.esb.services.security.publicKeyAlias" value="testAlias"/> <property name="org.jboss.soa.esb.services.security.publicKeyPassword" value="testPassword"/> <property name="org.jboss.soa.esb.services.security.publicKeyTransformation" value="RSA/ECB/PKCS1Padding"/> </properties> <properties name="registry"> <property name="org.jboss.soa.esb.registry.queryManagerURI" value="org.apache.juddi.v3.client.transport.wrapper.UDDIInquiryService#inquire"/> <property name="org.jboss.soa.esb.registry.lifeCycleManagerURI" value="org.apache.juddi.v3.client.transport.wrapper.UDDIPublicationService#publish"/> <property name="org.jboss.soa.esb.registry.securityManagerURI" value="org.apache.juddi.v3.client.transport.wrapper.UDDISecurityService#secure"/> <property name="org.jboss.soa.esb.registry.implementationClass" value="org.jboss.internal.soa.esb.services.registry.JAXRRegistryImpl"/> <property name="org.jboss.soa.esb.registry.factoryClass" value="org.apache.ws.scout.registry.ConnectionFactoryImpl"/> <property name="org.jboss.soa.esb.registry.user" value="root"/> <property name="org.jboss.soa.esb.registry.password" value="root"/> <property name="org.jboss.soa.esb.scout.proxy.transportClass" value="org.apache.ws.scout.transport.LocalTransport"/> <property name="org.jboss.soa.esb.scout.proxy.uddiVersion" value="3.0"/> <property name="org.jboss.soa.esb.scout.proxy.uddiNameSpace" value="urn:uddi-org:api_v3"/> <property name="org.jboss.soa.esb.registry.interceptors" value="org.jboss.internal.soa.esb.services.registry.InVMRegistryInterceptor, org.jboss.internal.soa.esb.services.registry.CachingRegistryInterceptor"/> <property name="org.jboss.soa.esb.registry.cache.maxSize" value="100"/> <property name="org.jboss.soa.esb.registry.orgCategory" value="org.jboss.soa.esb.:category"/> </properties> <properties name="transports" depends="core"> <property name="org.jboss.soa.esb.mail.smtp.host" value="localhost"/> <property name="org.jboss.soa.esb.mail.smtp.user" value="jbossesb"/> <property name="org.jboss.soa.esb.mail.smtp.password" value=""/> <property name="org.jboss.soa.esb.mail.smtp.port" value="25"/> <property name="org.jboss.soa.esb.mail.smtp.auth" value="true"/> <property name="org.jboss.soa.esb.ftp.localdir" value="/tmp"/> <property name="org.jboss.soa.esb.ftp.remotedir" value="/tmp"/> <property name="org.jboss.soa.esb.ftp.renameretry" value="10"/> <property name="org.jboss.soa.esb.ftp.timeout" value="0"/> <property name="org.jboss.soa.esb.jms.connectionPool" value="300"/> <property name="org.jboss.soa.esb.jms.sessionSleep" value="30"/> <property name="org.jboss.soa.esb.invm.expiryTime" value="300000"/> <property name="org.jboss.soa.esb.failure.detect.removeDeadEPR" value="true"/> <property name="org.jboss.soa.esb.exceptionOnDeliverFailure" value="true"/> <property name="org.jboss.soa.esb.aggregator.setOnProperties" value="false"/> </properties> <properties name="connection"> <property name="min-pool-size" value="5"/> <property name="max-pool-size" value="10"/> <property name="blocking-timeout-millis" value="5000"/> <property name="abandoned-connection-timeout" value="10000"/> <property name="abandoned-connection-time-interval" value="30000"/> </properties> <properties name="jca"> <property name="org.jboss.soa.esb.jca.activation.mapper.jms-ra.rar" value="org.jboss.soa.esb.listeners.jca.JBossActivationMapper"/> <property name="org.jboss.soa.esb.jca.activation.mapper.wmq.jmsra.rar" value="org.jboss.soa.esb.listeners.jca.WMQActivationMapper"/> </properties> <properties name="dbstore"> <property name="org.jboss.soa.esb.persistence.db.conn.manager" value="org.jboss.internal.soa.esb.persistence.manager.J2eeConnectionManager"/> <property name="org.jboss.soa.esb.persistence.db.datasource.name" value="java:/JBossESBDS"/> <property name="org.jboss.soa.esb.persistence.db.connection.url" value="jdbc:hsqldb:hsql://localhost:9001/"/> <property name="org.jboss.soa.esb.persistence.db.jdbc.driver" value="org.hsqldb.jdbcDriver"/> <property name="org.jboss.soa.esb.persistence.db.user" value="sa"/> <property name="org.jboss.soa.esb.persistence.db.pwd" value=""/> <property name="org.jboss.soa.esb.persistence.db.pool.initial.size" value="2"/> <property name="org.jboss.soa.esb.persistence.db.pool.min.size" value="2"/> <property name="org.jboss.soa.esb.persistence.db.pool.max.size" value="5"/> <property name="org.jboss.soa.esb.persistence.db.pool.test.table" value="pooltest"/> <property name="org.jboss.soa.esb.persistence.db.pool.timeout.millis" value="5000"/> </properties> <properties name="filters"> <property name="org.jboss.soa.esb.filter.1" value="org.jboss.internal.soa.esb.message.filter.MetaDataFilter"/> <property name="org.jboss.soa.esb.filter.2" value="org.jboss.internal.soa.esb.message.filter.GatewayFilter"/> </properties> <properties name="rules"> <property name="org.jboss.soa.esb.services.rules.continueState" value="false"/> <property name="org.jboss.soa.esb.services.rules.resource.scanner.interval" value="60"/> </properties> </esb>
And in META-INF directory of my web application I added the uddi.xml file; this is its content:
<?xml version="1.0" encoding="ISO-8859-1" ?> <uddi> <reloadDelay>5000</reloadDelay> <manager name="test-manager"> <nodes> <node> <name>default</name> <description>Main jUDDI node</description> <properties> <property name="serverName" value="soa-p1"/> <property name="serverPort" value="8880"/> </properties> <proxyTransport>org.jboss.internal.soa.esb.registry.client.JuddiRMITransport</proxyTransport> <custodyTransferUrl>/juddiv3/UDDICustodyTransferService</custodyTransferUrl> <inquiryUrl>/juddiv3/UDDIInquiryService</inquiryUrl> <publishUrl>/juddiv3/UDDIPublicationService</publishUrl> <securityUrl>/juddiv3/UDDISecurityService</securityUrl> <subscriptionUrl>/juddiv3/UDDISubscriptionService</subscriptionUrl> <subscriptionListenerUrl>/juddiv3/UDDISubscriptionListenerService</subscriptionListenerUrl> <juddiApiUrl>/juddiv3/JUDDIApiService</juddiApiUrl> <javaNamingFactoryInitial>org.jnp.interfaces.NamingContextFactory</javaNamingFactoryInitial> <javaNamingFactoryUrlPkgs>org.jboss.naming</javaNamingFactoryUrlPkgs> <javaNamingProviderUrl>jnp://soa-p1:1099</javaNamingProviderUrl> </node> <node> <name>node2</name> <description>Main jUDDI node</description> <properties> <property name="serverName" value="soa-p2"/> <property name="serverPort" value="8880"/> </properties> <proxyTransport>org.jboss.internal.soa.esb.registry.client.JuddiRMITransport</proxyTransport> <custodyTransferUrl>/juddiv3/UDDICustodyTransferService</custodyTransferUrl> <inquiryUrl>/juddiv3/UDDIInquiryService</inquiryUrl> <publishUrl>/juddiv3/UDDIPublicationService</publishUrl> <securityUrl>/juddiv3/UDDISecurityService</securityUrl> <subscriptionUrl>/juddiv3/UDDISubscriptionService</subscriptionUrl> <subscriptionListenerUrl>/juddiv3/UDDISubscriptionListenerService</subscriptionListenerUrl> <juddiApiUrl>/juddiv3/JUDDIApiService</juddiApiUrl> <javaNamingFactoryInitial>org.jnp.interfaces.NamingContextFactory</javaNamingFactoryInitial> <javaNamingFactoryUrlPkgs>org.jboss.naming</javaNamingFactoryUrlPkgs> <javaNamingProviderUrl>jnp://soa-p2:1099</javaNamingProviderUrl> </node> </nodes> </manager> </uddi>
Well when I try to call the ServiceInvoker, I get the following exception:
09:37:25,678 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) org.jboss.soa.esb.listeners.message.MessageDeliverException: Invocation exception. null 09:37:25,678 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) at org.jboss.soa.esb.client.ServiceInvoker.loadServiceClusterInfo(ServiceInvoker.java:580) 09:37:25,679 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) at org.jboss.soa.esb.client.ServiceInvoker.<init>(ServiceInvoker.java:176) 09:37:25,679 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) at org.jboss.soa.esb.client.ServiceInvoker.<init>(ServiceInvoker.java:157) 09:37:25,679 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) at org.jboss.soa.esb.client.ServiceInvoker.<init>(ServiceInvoker.java:199) . . 09:37:25,686 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) Caused by: java.lang.NullPointerException 09:37:25,686 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) at java.lang.Class.forName0(Native Method) 09:37:25,686 ERROR [stderr] (ajp-eapgwt1/10.24.5.4:8009-13) at java.lang.Class.forName(Class.java:247)
Can anybody tell me where I'm wrong? I'm fighting with this issue from 4 days
Thank you
Angelo