问题
I am new to WCF SOAP based services. I have a webpage which takes 3 fields and validates them in Javascript. After validation it sends them to a servlet. Now, in servlet I need to call a web service which is a WCF based SOAP service.
How should I proceed? Is it possible to make the call?
回答1:
Yes, it's possible to call, it doesn't matter it's a WCF web service. You just need to write a client to call the web service and use the client from within your servlet code.
There are enough SOAP web services frameworks out there that allow you to generate a client. You could keep it simple by using a JAX-WS client generated with wsimport or even manually building the message for the call by using something basic as SAAJ.
来源:https://stackoverflow.com/questions/23443471/regarding-wcf-soap-based-web-service-and-servlets