How to ignore extra WSDL operation when using JAX-WS?
I'm migrating from Apache Axis2 to JAX-WS and i'm having the following issue:
I have a large WSDL file of size = 140 KB, however my client application invokes only 2 operations, so i removed all the other operations from the WSDL.
I successfully generated the stubs using wsimport on the trimmed WSDL, and i put the original WSDL location in the Service constructor:
MyService stub = new MyService(new URL(<original WSDL location>), new QName(<package>, <MyServiceName>));
when i ran the client, i got the following exception:
The Endpoint validation failed to validate due to the following errors: :: Invalid Endpoint Interface :: :: The operation names in the WSDL portType do not match the method names in the SEI or Web service implementation class.
Because of that, i got the original WSDL again, run wsimport on it, but it fails this time, with this error:
[ERROR] undefined simple or complex type 'soapenc:Array'
line 1086 of file:/root/DecisionControllerWS.wsdl
Googling the error, JAX-WS doesn't support RPC/Encoding.
So i'm stuck here, can't work with the trimmed WSD, can't generate the stubs with the full WSDL!
Any advise? thanks in advance.