Ignore XML Validation for JAX-WS Clients

I have several JAX-WS services that I am trying to use, but the XML returned from the service (from which I cannot change) has an invalid DTD (throwing an XMLStreamReaderException because there are no publicId and systemId spaces between the spaces). How to make customers ignore poorly formed DTDs?

+8
java xml jax-ws
source share
1 answer

Invalid DTD part of WSDL ? If so, you can use the JAXWS catalog to read the XML locally, and then just call the service.

You need to download WSDL , fix it and save it locally. Then, after creating the Service instance, read the WSDL from your local storage. Update the endpoint property and call the service.

+1
source share

All Articles