Need to convert SOAP Response in SpringBoot (WebServivetemplate) to REST JSON. Currently SOAP Response is working fine...need to convert this as JSON input /output. Any logic in spring framework other than looping through XML document node by node.
Need to convert SOAP Response in SpringBoot (WebServivetemplate) to REST JSON. Currently SOAP Response is working fine...need to convert this as JSON input /output. Any logic in spring framework other than looping through XML document node by node.
follwoing is good example how can you directly convert it using jaxb
import org.springframework.oxm.jaxb.Jaxb2Marshaller;
@Bean
public Jaxb2Marshaller marshaller(){
Jaxb2Marshaller marshaller = new Jaxb2Marshaller();
// this package must match the package in the <generatePackage> specified in
// pom.xml
marshaller.setContextPath("phoneverify.wsdl");
return marshaller;
}