I am creating SOAP web service using Spring Boot SOAP Webservice project. If I use following code dynamically generated WSDL shows Operations.
@PayloadRoot(namespace = NAMESPACE_URI, localPart = "getCountryRequest")
@ResponsePayload
public GetCountryResponse getCountry(@RequestPayload GetCountryRequest request) {
This generates the wsdl:
...
<soapenv:Body>
<gs:getCountryRequest>
<gs:name>Something</gs:name>
</gs:getCountryRequest>
...
But I need request element to change like this (without suffix)
@PayloadRoot(namespace = NAMESPACE_URI, localPart = "getCountry")
@ResponsePayload
public GetCountryResponse getCountry(@RequestPayload GetCountry request) {
I need this because I'm replicating a legacy wsdl, this doesn't have any suffix in the request.
Actually I don't need the object to be GetCountry, but I need the wsdl the request to be:
...
<soapenv:Body>
<gs:getCountry>
<gs:name>Something</gs:name>
</gs:getCountry>
...
I learnt on this link SpringBoot SOAP webservice Dynamic WSDL generation not working If remove Request suffix from RequestPayload element how to change the Request suffix:
wsdl11Definition.setRequestSuffix("RQ");
wsdl11Definition.setResponseSuffix("RS");
But I need to remove the suffix entirely. Perhaps, It exists some Interceptor for change the wsdl.
Br.
I tried to change the name of the request in the xsd.