File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Services and the fly likes JAXWS client: overwriting namespace prefixes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "JAXWS client: overwriting namespace prefixes" Watch "JAXWS client: overwriting namespace prefixes" New topic

JAXWS client: overwriting namespace prefixes

peter coster

Joined: Jan 13, 2006
Posts: 26

I have to write a WS client for an application which name I won't mention, but that isn't exactly providing valid webservices.

I have to use a ****.dll?SOAP as the endpoint. There is no WSDL, so I've build one myself. Now that I try to test it I see that this application requires specific namespace prefixes:

What I mean is that I have to use the company name as the prefix for what you can see as . And that I have to use SOAP-ENV as prefix for the soap namespace. The problem is that the soap request that is generated by jaxws uses the more common lowercase soapenv prefix and uses n0 for the prefix in the message
I fail to find a way to do this in JAXWS. I have found a NamespacePrefixMapper in JAXB, but can't see how to invoke this from JAXWS (more specifically the JAXWS-MAVEN plugin.

I am using the latest version of both JAXWS and JAXB
[ November 12, 2008: Message edited by: peter coster ]
I agree. Here's the link:
subject: JAXWS client: overwriting namespace prefixes
jQuery in Action, 3rd edition