Hi,
I'm experiencing problems using Zoap and Jboss 2.1.
I think I have installed properly Zoap, or at least I have followed all the
instructions coming with the package.
I tried then to deploy an EJB as Soap service, but I'm getting some errors.
************* JBoss.xml ***************
<jboss>
<enterprise-beans>
<session>
<ejb-name>MySession</ejb-name>
<jndi-name>MySessionAB</jndi-name>
<configuration-name>SOAP-enabled Stateless
SessionBean</configuration-name>
</session>
</enterprise-beans>
<resource-managers />
<container-configurations>
<container-configuration
configuration-class="org.jboss.ejb.deployment.StatelessSessionContainerConfi
guration">
<container-name>SOAP-enabled Stateless SessionBean</container-name>
<container-invoker>org.jboss.ejb.plugins.zoap.SoapContainerInvoker</containe
r-invoker>
<container-invoker-conf>
<ReadMetaData>false</ReadMetaData>
<BindingClass>org.zoap.soap.meta.builtin.DefaultBinding</BindingClass>
<MetaDataFileName></MetaDataFileName>
<SerialisationPolicyClass>org.zoap.xml.SerialisationPolicy$DefaultSerialisat
ionPolicy</SerialisationPolicyClass>
</container-invoker-conf>
<container-interceptors>
<interceptor>org.jboss.ejb.plugins.LogInterceptor</interceptor>
<interceptor>org.jboss.ejb.plugins.SecurityInterceptor</interceptor>
<interceptor
transaction="Container">org.jboss.ejb.plugins.TxInterceptorCMT</interceptor>
<interceptor transaction="Container"
metricsEnabled="true">org.jboss.ejb.plugins.MetricsInterceptor</interceptor>
<interceptor
transaction="Container">org.jboss.ejb.plugins.StatelessSessionInstanceInterc
eptor</interceptor>
</container-interceptors>
<instance-pool>org.jboss.ejb.plugins.StatelessSessionInstancePool</instance-
pool>
<instance-cache></instance-cache>
<persistence-manager></persistence-manager>
<transaction-manager>org.jboss.tm.TxManager</transaction-manager>
<container-pool-conf>
<MaximumSize>100</MaximumSize>
<MinimumSize>10</MinimumSize>
</container-pool-conf>
</container-configuration>
</container-configurations>
</jboss>
*******************************************************************
********************* Java Client **************************************
import java.net.*;
import org.zoap.soap.meta.SoapBinding;
import org.zoap.soap.*;
class MySessionSoapClient
{
public static void main(String[] args) {
try {
URL proxyURL= new URL("http://localhost:2121/");
URL targetURL= new URL(proxyURL,"MySessionAB/");
SoapBinding newBinding=new
org.zoap.soap.meta.builtin.DefaultBinding();
MySession mySession=(MySession)
java.lang.reflect.Proxy.newProxyInstance(
Thread.currentThread().getContextClassLoader(),
new Class[] {MySession.class},
new
SoapInvocationHandler(null,proxyURL,targetURL,newBinding));
System.out.println("Calling echo():");
System.out.println("\t" + mySession.echo("hello"));
} catch(Exception e) {
e.printStackTrace();
System.out.println(e.toString());
}
}
}
*********************************************************************
********************** Errors on JBoss side **************************
[*** HttpServer ***]
[EMAIL PROTECTED]
iveRequest(,org.zoap.soap.HttpRequest@15da38,org.zoap.soap.HttpResponse@29c2
04):
<n1:Envelope n1:encodingStyle="http://soap.zoap.org/"
xmlns:n1="http://schemas.x
mlsoap.org/soap/envelope/"><n1:Body><n2:echo-5-Request
xmlns:n2="http://soap.zoa
p.org/broglia/MySession/"><n2:echo-5-Argument-0>hello</n2:echo-5-Argument-0>
</n2:
echo-5-Request></n1:Body></n1:Envelope>
[MySession] CONTAINER EXCEPTION:null
[MySession] java.lang.NullPointerException
[MySession] at
org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.
invoke(StatelessSessionContainer.java:440)
[MySession] at
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInte
rceptor.java:177)
[MySession] at
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.ja
va:195)
[MySession] at
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessi
onContainer.java:271)
[MySession] at
org.jboss.ejb.plugins.zoap.SoapContainerInvoker.receiveReques
t(SoapContainerInvoker.java:252)
[MySession] at
org.zoap.soap.HttpServer.processRequest(HttpServer.java:154)
[MySession] at de.infor.ce.http.Server.run(Server.java:264)
[MySession] at
de.infor.ce.thread.PooledThread.run(PooledThread.java:109)
[*** HttpServer ***]
[EMAIL PROTECTED]
iveRequest(,org.zoap.soap.HttpRequest@15da38,org.zoap.soap.HttpResponse@29c2
04):
encountered application exception java.rmi.ServerException: Container
exception
. Notify the container developers :-); nested exception is:
java.lang.NullPointerException while invoking container.
[*** HttpServer ***] java.rmi.ServerException: Container exception. Notify
the c
ontainer developers :-); nested exception is:
java.lang.NullPointerException
[*** HttpServer ***] java.lang.NullPointerException
[*** HttpServer ***] at
org.jboss.ejb.StatelessSessionContainer$ContainerInte
rceptor.invoke(StatelessSessionContainer.java:440)
[*** HttpServer ***] at
org.jboss.ejb.plugins.SecurityInterceptor.invoke(Secu
rityInterceptor.java:177)
[*** HttpServer ***] at
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterc
eptor.java:195)
[*** HttpServer ***] at
org.jboss.ejb.StatelessSessionContainer.invoke(Statel
essSessionContainer.java:271)
[*** HttpServer ***] at
org.jboss.ejb.plugins.zoap.SoapContainerInvoker.recei
veRequest(SoapContainerInvoker.java:252)
[*** HttpServer ***] at
org.zoap.soap.HttpServer.processRequest(HttpServer.ja
va:154)
[*** HttpServer ***] at de.infor.ce.http.Server.run(Server.java:264)
[*** HttpServer ***] at
de.infor.ce.thread.PooledThread.run(PooledThread.java
:109)
[*** HttpServer ***]
[EMAIL PROTECTED]
iveRequest(,org.zoap.soap.HttpRequest@15da38,org.zoap.soap.HttpResponse@29c2
04):
<n1:Envelope n1:encodingStyle="http://soap.zoap.org/"
xmlns:n1="http://schemas.x
mlsoap.org/soap/envelope/"><n1:Body><n1:Fault><n1:Detail><n2:ServerException
n3:
name="0" n4:detailMessage="Container exception. Notify the container
developers
:-)" xmlns:n2="http://xml.zoap.org/java/rmi/ServerException/"
xmlns:n3="http://x
ml.zoap.org/" xmlns:n4="http://xml.zoap.org/java/lang/Throwable/"><n5:detail
n6:
type="n7:NullPointerException" n3:name="1"
xmlns:n5="http://xml.zoap.org/java/rm
i/RemoteException/" xmlns:n6="http://www.w3.org/1999/XMLSchema-Instance"
xmlns:n
7="http://xml.zoap.org/java/lang/NullPointerException/"></n5:detail></n2:Ser
verE
xception></n1:Detail></n1:Fault></n1:Body></n1:Envelope>
****************************************************************************
*********
The EJB is a Session Stateless Session one with just one method "echo"
accepting a String as input parameter and returning the String itself.
Can someone please tell me what I'm missing?
Thanks very much in advance,
Andrea
--
--------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]