Is it possible to configure location ( schemaLocation and soap:address location ) in JAX-WS WSDL?
When I use the sample below, "servername" will be localhost, and "serverport" will be the local port number for the web application.
However, I want to reconfigure them as a proxy server name and server port, which redirects to the service. Is this possible and how can I achieve this?
The deployment environment includes Tomcat and Apache.
I have the following class of service:
@WebService public class AuthenticationService { .... public AuthenticationService(){} @WebMethod public AuthenticationResult checkAuthentication( @WebParam(name = "authentication") Authentication authentication, @WebParam(name = "privilege") Privilege privilege) { .... } }
When starting WSDL, it looks like this:
<definitions targetNamespace="http://authentication.service.ws.ijs/" name="AuthenticationServiceService"> <types> <xsd:schema> <xsd:import namespace="http://authentication.service.ws.ijs/" schemaLocation="http://servername:serverport/WebAppName/AuthenticationService?xsd=1"/> </xsd:schema> </types> <message name="checkAuthentication"> <part name="parameters" element="tns:checkAuthentication"/> </message> <message name="checkAuthenticationResponse"> <part name="parameters" element="tns:checkAuthenticationResponse"/> </message> <portType name="AuthenticationService"> <operation name="checkAuthentication"> <input wsam:Action="http://authentication.service.ws.ijs/AuthenticationService/checkAuthenticationRequest" message="tns:checkAuthentication"/> <output wsam:Action="http://authentication.service.ws.ijs/AuthenticationService/checkAuthenticationResponse" message="tns:checkAuthenticationResponse"/> </operation> </portType> <binding name="AuthenticationServicePortBinding" type="tns:AuthenticationService"> <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> <operation name="checkAuthentication"> <soap:operation soapAction=""/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> </operation> </binding> <service name="AuthenticationServiceService"> <port name="AuthenticationServicePort" binding="tns:AuthenticationServicePortBinding"> <soap:address location="http://servername:serverport/WebAppName/AuthenticationService"/> </port> </service> </definitions>
Any help would be greatly appreciated.
noddy
source share