当我尝试访问我的网络服务时,我收到了无终点和附件支持错误。
我可以进行授权,但由于此“无终点”错误,我无法访问网络服务。
Console:
WARNING: Unable to find required classes (javax.activation.DataHandler and javax.mail.internet.MimeMultipart). Attachment support is disabled.
AxisFault
faultCode: {http://xml.apache.org/axis/}Server.NoEndpoint
faultSubcode:
faultString: No endpoint <------------
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}exceptionName:org.apache.axis.NoEndPointException
{http://xml.apache.org/axis/}stackTrace:No endpoint <--------------
at functions.rfc.sap.document.sap_com.Zws001_BindingStub.ZF_GET_CUSTOMERS(Zws001_BindingStub.java:414)
at test.test1.main(test1.java:23)
{http://xml.apache.org/axis/}hostname:logosi3
No endpoint
at functions.rfc.sap.document.sap_com.Zws001_BindingStub.ZF_GET_CUSTOMERS(Zws001_BindingStub.java:414)
at test.test1.main(test1.java:23)
答案 0 :(得分:1)
我通过使用locator类调用服务而不是直接加载存根类 -
解决了这个问题GlobalWeatherLocator locator = new GlobalWeatherLocator();
String cityName = "delhi";
String countryName = "India";
String data = locator.getGlobalWeatherSoap().getWeather(cityName, countryName);
答案 1 :(得分:0)
可以通过以下方法解决:首先调用Locator文件,然后调用要在SOAP Webservice中调用的方法。 可以使用以下代码:
ADUserProdAuthMainServiceLocator loc=new ADUserProdAuthMainServiceLocator();
Employee result=loc.getADUserProdAuthMain().run(username, password);