Just to be clear, I think the issue we're talking about is that Axis
is converting our applications exceptions into AxisFaults, but we don't
have as much control over the structure of this AxisFaults as we like.

For me the issue seems to be that AxisFault.makeFault() is hardwired
pretty deep in Axis and doesn't have the same configurability other
things like the normal serialization process has. I'm still not sure
that there isn't some way to configure it that I just haven't found.

Another solution is to declare your service code 'throws AxisFault'
and generate the AxisFaults yourself. That does give more control, but
it's an awful nuisance. And it ties your code to the Axis code.

Does JAX-RPC have anything to say about this?


MJS asked:
>As I see, Nelson Minar has similar problem - could You tell mi what is
>this Utils.convertException method? I can't find it in axis 1.1 api.

I think you're referring to this code snippet I posted as an example
of creating AxisFaults myself in my service code:

  public Foo myServiceMethod() throws Exception {
    try {
      ...
    } catch (Exception e) {
      throw Utils.convertException(e);
    }
  }

Utils.convertException() isn't in Axis; just an example of what my own
code is doing. Something like:

  public static AxisFault convertException(Exception e) {
    AxisFault axisFault = AxisFault.makeFault(e);
    // modify axisFault here somehow
    return axisFault;
  }

Reply via email to