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 Steve Loughran <st...@apache.org> on 2005/10/26 13:01:14 UTC

[Axis2] AxisFault

I am looking at the current axis fault stuff. Is anybody actively 
working on this, or am I free to add enhancements?

Specifically:

1. All the bits of a SOAPFAult, including random XML

2. Axis1 features: stack trace extractions, hostname, http error codes.

3. Tweak how we map from a java fault to a SOAPFault. If a fault says 
that it can provide a fault message then we ask it for it directly. This 
lets people's classes (like my BaseFault) generate my own fault with no 
intervention.

WS-A says that addressing faults are handled differently, with most of 
the stuff in special headers, rather than just the body. How does Axis2 
handle that in both generation and receipt? Maybe an AxisFault should 
have a header section where you can add new header elements for both 
outbound and inbound calls.

-steve



Re: [Axis2] AxisFault

Posted by Steve Loughran <st...@apache.org>.
Glen Daniels wrote:
> +1
> 
> Axis 1.X's AxisFault does have the capability to add and access headers 
> as you request below.  You might want to crib whatever you can from there.

That is exactly my plan.

> We might explore the utility of a WS-Addressing-specific fault subclass 
> which gives a nice API on top of the header-related stuff.
> 

yeah. Though I still expect all received faults to be turned back into 
AxisFaults, with all the stuff  underneath.


Re: [Axis2] AxisFault

Posted by Glen Daniels <gl...@thoughtcraft.com>.
+1

Axis 1.X's AxisFault does have the capability to add and access headers 
as you request below.  You might want to crib whatever you can from there.

We might explore the utility of a WS-Addressing-specific fault subclass 
which gives a nice API on top of the header-related stuff.

--G

Sanjiva Weerawarana wrote:
> Most definitely +1 .. go for it!
> 
> Sanjiva.
> 
> On Wed, 2005-10-26 at 12:01 +0100, Steve Loughran wrote:
> 
>>I am looking at the current axis fault stuff. Is anybody actively 
>>working on this, or am I free to add enhancements?
>>
>>Specifically:
>>
>>1. All the bits of a SOAPFAult, including random XML
>>
>>2. Axis1 features: stack trace extractions, hostname, http error codes.
>>
>>3. Tweak how we map from a java fault to a SOAPFault. If a fault says 
>>that it can provide a fault message then we ask it for it directly. This 
>>lets people's classes (like my BaseFault) generate my own fault with no 
>>intervention.
>>
>>WS-A says that addressing faults are handled differently, with most of 
>>the stuff in special headers, rather than just the body. How does Axis2 
>>handle that in both generation and receipt? Maybe an AxisFault should 
>>have a header section where you can add new header elements for both 
>>outbound and inbound calls.
>>
>>-steve
>>
>>
> 
> 

Re: [Axis2] AxisFault

Posted by Sanjiva Weerawarana <sa...@opensource.lk>.
Most definitely +1 .. go for it!

Sanjiva.

On Wed, 2005-10-26 at 12:01 +0100, Steve Loughran wrote:
> I am looking at the current axis fault stuff. Is anybody actively 
> working on this, or am I free to add enhancements?
> 
> Specifically:
> 
> 1. All the bits of a SOAPFAult, including random XML
> 
> 2. Axis1 features: stack trace extractions, hostname, http error codes.
> 
> 3. Tweak how we map from a java fault to a SOAPFault. If a fault says 
> that it can provide a fault message then we ask it for it directly. This 
> lets people's classes (like my BaseFault) generate my own fault with no 
> intervention.
> 
> WS-A says that addressing faults are handled differently, with most of 
> the stuff in special headers, rather than just the body. How does Axis2 
> handle that in both generation and receipt? Maybe an AxisFault should 
> have a header section where you can add new header elements for both 
> outbound and inbound calls.
> 
> -steve
> 
> 


Re: [Axis2] AxisFault

Posted by Eran Chinthaka <ch...@opensource.lk>.

Steve Loughran wrote:

> <Stuff removed for clarity>


> There is some fun here in that we have different faults for SOAP1.1
> and SOAP1.2. So while I could ask for a fault, I have to decide
> whether it is 1.1 or 1.2. hmm.

Did you look at how existing code handles that ? See the interfaces I
have put and I hope you agree with me that we should have SOAP 1.2
programming model. But depending on the SOAP version, when you
serialize, you get the correct xml.

-- Chinthaka



Re: [Axis2] AxisFault

Posted by Steve Loughran <st...@apache.org>.
Steve Loughran wrote:
> 
> I am looking at the current axis fault stuff. Is anybody actively 
> working on this, or am I free to add enhancements?
> 
> Specifically:
> 
> 1. All the bits of a SOAPFAult, including random XML

easily added to AxisFault, along with headers. Can put this stuff in 
when an exception comes in; right now it is dropped on the floor.

> 
> 2. Axis1 features: stack trace extractions, hostname, http error codes.
> 
> 3. Tweak how we map from a java fault to a SOAPFault. If a fault says 
> that it can provide a fault message then we ask it for it directly. This 
> lets people's classes (like my BaseFault) generate my own fault with no 
> intervention.

There is some fun here in that we have different faults for SOAP1.1 and 
SOAP1.2. So while I could ask for a fault, I have to decide whether it 
is 1.1 or 1.2. hmm.


public interface SoapFaultSource {

     /**
      * The full SOAPFault to send back. This will become the body of a 
message.
      * @return the SOAPFault to return as the body of a message.
      */
     SOAPFault getSOAPFault();

     /**
      * Get any Headers to include in the message.
      * @return an iterator over headers, or null for no headers of 
interest.
      */
     Iterator getHeaders();
}


> 
> WS-A says that addressing faults are handled differently, with most of 
> the stuff in special headers, rather than just the body. How does Axis2 
> handle that in both generation and receipt? Maybe an AxisFault should 
> have a header section where you can add new header elements for both 
> outbound and inbound calls.
> 
> -steve
> 
> 


Re: [Axis2] AxisFault

Posted by Eran Chinthaka <ch...@opensource.lk>.

Steve Loughran wrote:

>
> I am looking at the current axis fault stuff. Is anybody actively
> working on this, or am I free to add enhancements?

I "was" working on this and I know this is not complete. If you can
please please go ahead and do it.

>
> Specifically:
>
> 1. All the bits of a SOAPFAult, including random XML
>
> 2. Axis1 features: stack trace extractions, hostname, http error codes.
>
> 3. Tweak how we map from a java fault to a SOAPFault. If a fault says
> that it can provide a fault message then we ask it for it directly.
> This lets people's classes (like my BaseFault) generate my own fault
> with no intervention.
>
> WS-A says that addressing faults are handled differently, with most of
> the stuff in special headers, rather than just the body. How does
> Axis2 handle that in both generation and receipt? Maybe an AxisFault
> should have a header section where you can add new header elements for
> both outbound and inbound calls.

I didn't add WS-A stuff for fault handling at all. Only the basic stuff.
You can go ahead with it.

-- Chinthaka

>
> -steve
>
>
>
>