You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Tom Jordahl <to...@macromedia.com> on 2002/09/06 16:09:09 UTC

RE: custom faults

> Will serialization of fault data be supported in Release 1?  
> Haven't seen any references to this in the RC1 release notes.

Unless someone drops an implementation on our heads early next week, no, Axis wont serialize fault data for 1.0.

I will say that the next soap builders interop event is coming up in October and one of the test groups is faults (with data):
  http://soapinterop.java.sun.com/soapbuilders/r4/index.html

This is incentive for that work to get done by one of the committers. :-)

Here is some design on the fly:
We need to figure out how other (the JAX-RPC RI for instance) relates the element in the <details> to an exception class on the client.  Axis put the class name in a details element, but that is just plain wrong (I did that ;-).

Here is how I think we can do that:

We will need some meta-data in the runtime that keeps a list of fault part QNames and their corresponding classes.  WSDL2Java would have to generate this.  WSDL limits faults to a single message part, so the table lookup should be unique.  We can then search each element in details, looking up the QNames of each to see if we get a match in the table, if we do, we take that element and run it through the deserialization system  to fill in the data in an object of the class we found in the table. I think this is a tricky part getting the fault processor and the deserialization subsystem hooked together.  I may be making a mountain out of a mole hill.

If we can't find anything in the meta data, we just return the SOAPFault (aka AxisFault).

Thoughts (and implementation code!) would be very much appreciated!

--
Tom Jordahl
Macromedia Server Development



-----Original Message-----
From: Agrawal, Anuj (Anuj)** CTR ** [mailto:agrawal@lucent.com]
Sent: Friday, September 06, 2002 9:01 AM
To: 'axis-user@xml.apache.org'
Subject: RE: custom faults


Tom -

Will serialization of fault data be supported in Release 1?  Haven't seen any references to this in the RC1 release notes.

Thanks.
Anuj.

> -----Original Message-----
> From: Tom Jordahl [mailto:tomj@macromedia.com]
> Sent: Tuesday, August 27, 2002 10:23 AM
> To: 'axis-user@xml.apache.org'; 'axis-dev@xml.apache.org'
> Subject: RE: custom faults
> 
> Serialization of fault data is not currently implemented in Axis.
> 
> As to when it will be done, the standard Open Source answer is:
>  "Sooner, if you help."
> 
> This has been on my (and others) TODO list for a while, we 
> just haven't gotten it done.
> 
> --
> Tom Jordahl
> Macromedia Server Development
> 
> -----Original Message-----
> From: Geza.Szocs@nokia.com [mailto:Geza.Szocs@nokia.com]
> Sent: Tuesday, August 27, 2002 4:33 AM
> To: axis-user@xml.apache.org; axis-dev@xml.apache.org
> Subject: custom faults
> 
> 
> Hi,
> 
>  As far as I know the final mechanism to handle custom
> SOAP faults is missing in Axis. Although, looking at the source
> code, it looks like the problem is moving towards a solution.
> Is somebody working on this issue ? Can you developers tell us
> a probable date when this will be ready ? 
>  The thing is, that I need to solve this problem ASAP, meaning
> in the next days. Concluding the previous experiences, the thing
> seems to work if one can somehow put it's custom data into the
> AxisFault's faultDetail field. So what we have right now is a custom
> exception class dervied from AxisFault and generated from a WSDL.
> What we (I) need is way to serialize my custom data from the exception
> and insert it into the detail field of the AxisFault object. Looking
> at the source of the generated exceptions, it seems that 
> there are things
> (like TypeDesc, etc) that help the serialization of these exceptions.
> This could be made by an exception-serializer handler or 
> something like
> that. 
>   What do you guys thing is the solution to do this ? Or is this
> done yet in the latest nightly ? If not please suggest me a starting
> direction. I assume that a BeanSerializer should digest these 
> exceptions
> somehow. How to do it ?
>   
>   Thanx for help, Geza
> 
> P.S. Please respond to the axis-user list. 
> 

URGENT: validation

Posted by Gionata Gelati <ge...@sparc20.ing.unimo.it>.
By the way, the prompt gives us the following message: bash-2.03$ -
Problem with servlet engine config file: /export/home/httpd/jakarta
-tomcat-4.0.1/webapps/axis//WEB-INF/server-config.wsdd
Any idea?
Jonathan



RE: URGENT: no validation

Posted by Allegar Robert <al...@bah.com>.
Jonathan,

Check that you have a JAXP 1.1 compliant XML parser either on you system
classpath or in the \webapps\axis\WEB-INF\lib\ directory under the Axis
installation. Just download a more recent version of Xerces and you should
be ok. The installation instructions for Axis are at
http://cvs.apache.org/viewcvs.cgi/~checkout~/xml-axis/java/docs/install.html
and I've found them to be very helpful.

Also the other error you're getting about the server-config.wsdd file not
being found -- This isn't a fatal error. If you want, you can copy the
server-config.wsdd file from inside the axis.jar to the WEB-INF directory
and the message will go away. I think when you register your first
webservice the file gets created automatically anyway.

Regards,
	Rob

-----Original Message-----
From: Gionata Gelati [mailto:gelati@sparc20.ing.unimo.it]
Sent: Friday, September 06, 2002 12:33 PM
To: 'axis-user@xml.apache.org'
Subject: URGENT: no validation


Hello,
  we are trying to install axis Rc1. Everything is fine with the
publicaiton
of simple Web Services, BUT we are not able to validate the installation
through the Validate option.
We get the following:
Exception report

message Internal Server Error

description The server encountered an internal error (Internal Server
Error) that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: Servlet.init() for servlet jsp threw
exception
	at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:871)
	at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:615)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:214)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:201)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:2
46)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2344)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164
)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170
)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:462)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:163)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:
1011)
	at
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1106
)
	at java.lang.Thread.run(Thread.java:536)


root cause

java.lang.ClassCastException:
org.apache.crimson.jaxp.DocumentBuilderFactoryImpl
	at
javax.xml.parsers.DocumentBuilderFactory.newInstance(DocumentBuilderFactory.
java:103)
	at
org.apache.jasper.parser.ParserUtils.parseXMLDocument(ParserUtils.java:183)
	at
org.apache.jasper.compiler.TldLocationsCache.processWebDotXml(TldLocationsCa
che.java:165)
	at
org.apache.jasper.compiler.TldLocationsCache.(TldLocationsCache.java:138)
	at
org.apache.jasper.EmbededServletOptions.(EmbededServletOptions.java:324)
	at org.apache.jasper.servlet.JspServlet.init(JspServlet.java:266)
	at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:852)
	at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:615)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:214)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:201)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:2
46)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2344)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164
)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170
)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:462)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:163)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:
1011)
	at
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1106
)
	at java.lang.Thread.run(Thread.java:536)

Any suggestion?
Thanks for your interest
Jonathan



URGENT: no validation

Posted by Gionata Gelati <ge...@sparc20.ing.unimo.it>.
Hello,
  we are trying to install axis Rc1. Everything is fine with the
publicaiton
of simple Web Services, BUT we are not able to validate the installation
through the Validate option.
We get the following:
Exception report

message Internal Server Error

description The server encountered an internal error (Internal Server
Error) that prevented it from fulfilling this request.

exception 

javax.servlet.ServletException: Servlet.init() for servlet jsp threw
exception
	at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:871)
	at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:615)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2344)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:462)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:163)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:1011)
	at
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1106)
	at java.lang.Thread.run(Thread.java:536)


root cause 

java.lang.ClassCastException: org.apache.crimson.jaxp.DocumentBuilderFactoryImpl
	at
javax.xml.parsers.DocumentBuilderFactory.newInstance(DocumentBuilderFactory.java:103)
	at
org.apache.jasper.parser.ParserUtils.parseXMLDocument(ParserUtils.java:183)
	at
org.apache.jasper.compiler.TldLocationsCache.processWebDotXml(TldLocationsCache.java:165)
	at
org.apache.jasper.compiler.TldLocationsCache.(TldLocationsCache.java:138)
	at
org.apache.jasper.EmbededServletOptions.(EmbededServletOptions.java:324)
	at org.apache.jasper.servlet.JspServlet.init(JspServlet.java:266)
	at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:852)
	at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:615)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2344)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:462)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:163)
	at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
	at
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:1011)
	at
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1106)
	at java.lang.Thread.run(Thread.java:536)

Any suggestion?
Thanks for your interest
Jonathan