Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Apache Axis Exception response question  RSS feed

 
Ra Carter
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When throwing an exception in one of my Axis service methods I notice that there is a detail section in the soap response. This is Axis 1.1 btw and the code looks like this:

which produces output like this:

I don't mind the detail section and I believe it is used for custom object properties, but is there any way to remove the hostname node or control the exception output? In this case I don't want to reveal my server host name.
 
R Srini
Ranch Hand
Posts: 215
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi. I haven't used Axis1, but here are a couple of thoughts in case this is still a problem:

1. Have you considered a custom fault? If not, please check this article.
2. This is the documentation (hopefully applicable to your version, though I am not sure) for the Axis Fault. If you look at the constructors, you can see a couple of them that let you specify the detail element. Construct an Element, and put whatever you like in there, or instead of
you could always wrap your exception in an axis fault:
Please check it out and let us know what works for you! All the best
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!