cancel
Showing results for 
Search instead for 
Did you mean: 

how to consume ABAP web service in webdynpro

Former Member
0 Kudos

Hi,

I have to consume one ABAP web service in webdynpro for Java, I can test & run the web service using Transaction WSADMIN, but how do I use it in webdynpro. I tried using WSDL URL, but WebService Model Creation wizard failed to load the wsdl, I also saved the wsdl file locally & tried, but no success.

Is there any way, we can use ABAP web service in webdynpro.

Thanks in advance.

Deepak.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

What is the error when the wizard fails?

Do you have any data type that is not supported?

Regards

Ayyapparaj

Former Member
0 Kudos

In NWDS, it says "Error in loading WSDl file. Please check error logs for more details".

some part of the log generated is as below

Exception : com.sap.tc.webdynpro.model.webservice.exception.WSModelRuntimeException: Exception on creation of service metadata for WSDL URL http://<hostname>:8000/sap/bc/srt/rfc/sap/YSALES_ORDER?sap-client=100&wsdl=1.1 and service factory configuration

Caused by: com.sap.engine.services.webservices.jaxrpc.exceptions.WebserviceClientException: GenericServiceFactory initialization problem. Could not load web service model. See nested exception for details.

at com.sap.engine.services.webservices.espbase.client.dynamic.impl.DGenericServiceImpl.generateProxyFiles(DGenericServiceImpl.java:149)

at com.sap.engine.services.webservices.espbase.client.dynamic.impl.DGenericServiceImpl.<init>(DGenericServiceImpl.java:49)

at com.sap.engine.services.webservices.espbase.client.dynamic.GenericServiceFactory.createService(GenericServiceFactory.java:71)

at com.sap.tc.webdynpro.model.webservice.metadata.WSModelInfo.getOrCreateWsrService(WSModelInfo.java:411)

... 53 more

Caused by: com.sap.engine.services.webservices.jaxrpc.exceptions.ProxyGeneratorException: Proxy Generator Error. Problem with WSDL file parsing. See nested message.

at com.sap.engine.services.webservices.jaxrpc.wsdl2java.ProxyGenerator.generateProxy(ProxyGenerator.java:182)

at com.sap.engine.services.webservices.espbase.client.dynamic.impl.DGenericServiceImpl.generateProxyFiles(DGenericServiceImpl.java:146)

... 56 more

Caused by: com.sap.engine.lib.xml.util.NestedException: IO Exception occurred while parsing file:Cannot connect to http://<hostname>:8000/sap/bc/srt/rfc/sap/YSALES_ORDER?sap-client=100&wsdl=1.1 , passing via http proxy: :80: Connection refused: connect -> java.io.IOException: Cannot connect to http://<hostname>:8000/sap/bc/srt/rfc/sap/YSALES_ORDER?sap-client=100&wsdl=1.1 , passing via http proxy: :80: Connection refused: connect

at com.sap.engine.services.webservices.wsdl.WSDLDOMLoader.loadDOMDocument(WSDLDOMLoader.java:1038)

at com.sap.engine.services.webservices.wsdl.WSDLDOMLoader.loadWSDLDocument(WSDLDOMLoader.java:1125)

at com.sap.engine.services.webservices.jaxrpc.wsdl2java.ProxyGenerator.generateProxy(ProxyGenerator.java:178)

... 57 more

Caused by: java.io.IOException: Cannot connect to http://<hostname>:8000/sap/bc/srt/rfc/sap/YSALES_ORDER?sap-client=100&wsdl=1.1 , passing via http proxy: :80: Connection refused: connect

at com.sap.engine.services.webservices.tools.WSDLDownloadResolver.resolveEntity(WSDLDownloadResolver.java:161)

at com.sap.engine.services.webservices.wsdl.WSDLDOMLoader.loadDOMDocument(WSDLDOMLoader.java:1018)

... 59 more

Let me know if you need more details.

Thanks

Deepak.

Former Member
0 Kudos

Hi,

Caused by: com.sap.engine.lib.xml.util.NestedException: IO Exception occurred while parsing file:Cannot connect to http://<hostname>:8000/sap/bc/srt/rfc/sap/YSALES_ORDER?sap-client=100&wsdl=1.1 , passing via http proxy: :80: Connection refused: connect -> java.io.IOException: Cannot connect to http://<hostname>:8000/sap/bc/srt/rfc/sap/YSALES_ORDER?sap-client=100&wsdl=1.1 , passing via http proxy: :80: Connection refused: connect

Are you able to access the above link from browser, seems to be a connection issue.

Regards

Ayyapparaj

Former Member
0 Kudos

yes, I can open the wsdl using the browser with the same url,

even I am able to test & run the web service using WSADMIN transaction,

which opens it in a browser for test run.

still wsdl is not getting loaded in NWDS.

I also tried to create a web service system in VC, but there also it failed to ping.

former_member751941
Active Contributor
0 Kudos

Hi Deepak,

First Close Your NWDS IDE then Open NWDS IDE and try to Import Adaptive Web Service Model.

Make sure you are using correct userid and password (ECC System) and your wsdl doesnu2019t contain any space. If it is working from WSADMIN you can definitely import it as a WD Model.

Regards,

Mithu

Former Member
0 Kudos

Mithu,

thanks for the information,

but already tried this so many times with no success.

any other idea?

Kind Regards

Deepak.

former_member751941
Active Contributor
0 Kudos

Hi Deepak,

We have faced same problem. But it is solved just be closing IDE.

Create a new local test project inside it try to import the model and then check whether you are getting same problem or not.

Regards,

Mithu