You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Pushkin Reddy <pu...@gmail.com> on 2008/05/05 09:59:44 UTC
Axis2 - Fault Inheritance
Hi,
I'm trying to use a contract first approach with Axis2 (1.3/1.4) to handle a
fault hierarchy scenario. As a test, I used the following WSDL with
WSDL2Java to generate stubs for a service with a simple method that throws a
BaseFault exception. It also contains a definition for DerivedFault as a
subclass of BaseFault. I don't see an exception class generated for
DerivedFault nor any way in which I can throw the DerivedFault in the
service implementation. What am I missing here? (The same WSDL processed
with WSDL2Java from Axis 1.4 outputs exception classes for both faults
correctly).
Thanks!
Pushkin
EXAMPLE.WSDL:
=============
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="http://example"
xmlns:apachesoap="http://xml.apache.org/xml-soap"
xmlns:tns="http://example"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:types>
<schema elementFormDefault="qualified" targetNamespace="http://example"
xmlns="http://www.w3.org/2001/XMLSchema" xmlns:apachesoap="
http://xml.apache.org/xml-soap" xmlns:tns="http://example" xmlns:intf="
http://example" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
<element name="methodRequest">
<complexType>
<sequence/>
</complexType>
</element>
<element name="methodResponse">
<complexType>
<sequence/>
</complexType>
</element>
<complexType name="BaseFaultType">
<sequence/>
</complexType>
<complexType name="DerivedFaultType">
<complexContent>
<extension base="tns:BaseFaultType">
<sequence/>
</extension>
</complexContent>
</complexType>
<element name="BaseFault" type="tns:BaseFaultType"/>
<element name="DerivedFault" type="tns:DerivedFaultType"/>
</schema>
</wsdl:types>
<wsdl:message name="methodRequestMessage">
<wsdl:part element="tns:methodRequest" name="parameters"/>
</wsdl:message>
<wsdl:message name="methodResponseMessage">
<wsdl:part element="tns:methodResponse" name="return"/>
</wsdl:message>
<wsdl:message name="BaseFaultMessage">
<wsdl:part element="tns:BaseFault" name="fault"/>
</wsdl:message>
<wsdl:message name="DerivedFaultMessage">
<wsdl:part element="tns:DerivedFault" name="fault"/>
</wsdl:message>
<wsdl:portType name="Example">
<wsdl:operation name="method">
<wsdl:input message="tns:methodRequestMessage"
name="methodRequest"/>
<wsdl:output message="tns:methodResponseMessage"
name="methodResponse"/>
<wsdl:fault message="tns:BaseFaultMessage" name="BaseException"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="ExampleSoapBinding" type="tns:Example">
<wsdlsoap:binding style="document" transport="
http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="method">
<wsdlsoap:operation soapAction=""/>
<wsdl:input name="methodRequest">
<wsdlsoap:body use="literal"/>
</wsdl:input>
<wsdl:output name="methodResponse">
<wsdlsoap:body use="literal"/>
</wsdl:output>
<wsdl:fault name="BaseException">
<wsdlsoap:fault name="BaseException" use="literal"/>
</wsdl:fault>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="ExampleService">
<wsdl:port binding="tns:ExampleSoapBinding" name="Example">
<wsdlsoap:address location="http://localhost/services/example"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
================
Re: cached archive files not deleted
Posted by SG...@intellicare.com.
Deepal,
Thanks for your reply.
Deepal Jayasinghe <de...@opensource.lk> wrote on 05/22/2008 01:34:45 AM:
> > In my Tomcat work directory (work\Catalina\localhost\axis2) I'm getting
> > multiple copies of the archives (jar, aar, mar):
> > axis211221antlr-2.7.6.jar
> > axis217411antlr-2.7.6.jar
> >
> Yes , Axis2 creates temp files from your services and modules , and
> create a class loader from that. In that way we can ensure better
> performance. This help us a lot when we have service aar or mar with
> third party library inside it.
I'm not questioning why temp files are created ....
Also in my original post:
>> ... A new one gets generated each time I restart Tomcat. On my Windows
XP
>> system, these are deleted each time Tomcat stops, but not on our Linux
>> systems.
I am trying to find out why they are not deleted at some point.
Do others have this problem? Is there something incorrect about my system
(permissions? ownership?)?
Have I missed a configuration setting somewhere?
Your explanation of why the temp files are created is appreciated.
Any suggestions about why they are not deleted before the next time they
are created would be even more appreciated!
- Steve
______________________________________________
Steve Gruverman, Programmer
IntelliCare, Inc. | A Medco Health Solutions Company
500 Southborough Drive | South Portland ME 04106
p: (207) 253-2152 | f: (207) 773-1857
w: www.intellicare.com | e: sgruverman@intellicare.com
>
> > I'm trying this question again:
> >
> >
> > Not sure if this is an Axis2 issue, Tomcat issue or what):
> >
>
> Thank you!
> Deepal
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>
> --
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
Re: cached archive files not deleted
Posted by Deepal Jayasinghe <de...@opensource.lk>.
> I'm trying this question again:
>
>
> Not sure if this is an Axis2 issue, Tomcat issue or what):
>
> In my Tomcat work directory (work\Catalina\localhost\axis2) I'm getting
> multiple copies of the archives (jar, aar, mar):
> axis211221antlr-2.7.6.jar
> axis217411antlr-2.7.6.jar
>
Yes , Axis2 creates temp files from your services and modules , and
create a class loader from that. In that way we can ensure better
performance. This help us a lot when we have service aar or mar with
third party library inside it.
Thank you!
Deepal
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
cached archive files not deleted
Posted by SG...@intellicare.com.
I'm trying this question again:
Not sure if this is an Axis2 issue, Tomcat issue or what):
In my Tomcat work directory (work\Catalina\localhost\axis2) I'm getting
multiple copies of the archives (jar, aar, mar):
axis211221antlr-2.7.6.jar
axis217411antlr-2.7.6.jar
etc
A new one gets generated each time I restart Tomcat. On my Windows XP
system, these are deleted each time Tomcat stops, but not on our Linux
systems.
We run out of disk space pretty fast unless we manually clean these up.
Any ideas on what's going on here - and how to prevent it?
Thanks,
Steve
______________________________________________
Steve Gruverman
IntelliCare, Inc. | A Medco Health Solutions Company
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
cached archive files not deleted
Posted by SG...@intellicare.com.
In my Tomcat work directory (work\Catalina\localhost\axis2) I'm getting
multiple copies of the archives (jar, aar, mar):
axis211221antlr-2.7.6.jar
axis217411antlr-2.7.6.jar
etc
A new one gets generated each time I restart Tomcat. On my Windows XP
system, these are deleted each time Tomcat stops, but not on our Linux
systems.
We run out of disk space pretty fast unless we manually clean these up.
I've looked around for a configuration setting (not sure if this is an Axis
issue, Tomcat issue or what).
How do I turn this off?
Thanks,
Steve
______________________________________________
Steve Gruverman
IntelliCare, Inc. | A Medco Health Solutions Company
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org