cancel
Showing results for 
Search instead for 
Did you mean: 

Exception while Invoking Webservice

arunneerolil
Contributor
0 Kudos

Hi All,

I am getting the following error while invoking a web service,

java.rmi.RemoteException: Service call exception; nested exception is: com.sap.engine.services.webservices.jaxrpc.exceptions.InvalidResponseCodeException: Invalid Response Code: (401) Unauthorized.

Can anyone help.

Thanks in Advance

Chemmanz

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

If you use Adpative WebService thn you can configure those on VisualAdmin also.

Check the blog /people/anilkumar.vippagunta2/blog/2006/12/13/secured-webservices-ii

Regards,ANilkumar

Former Member
0 Kudos

Hi All,

Im getting a similar error, while testing the demoszenario "Service-Enabled Procurement Scenario" from the SAP discovery system. The error appears in the first step when a salesorder should be created via a soap-adapter from an adobe offline form.

The error message in the status field is:

Error: RemoteException: Service call exception; nested exception is:

com.sap.engine.services.webservices.jaxrpc.exceptions.InvalidResponseCodeException: Invalid Response Code: (401) Unauthorized. The requested URL was:http://iwdfvm2160:51080/XISOAPAdapter/MessageServlet?channel=:WebService:SO_WS_SOAP_SENDER

It would be nice if somebody could tell us how to set the authorization.

Thanks and regards

marlies

Former Member
0 Kudos

Hi Chemmanz,

This error message appears when you dont have the necessary authorizations to access the web service.

Thanks,

Sam

arunneerolil
Contributor
0 Kudos

Hi samta,

How can i pass the authorization (userid/pwd) information along with the request ??

Regards,

Chemmanz

Former Member
0 Kudos

Chemmanz,

You have generated WS Request object with execute method, i.e. you are already have SomeWs_Request.execute(). So just before execution call

 SomeWs_Request._setUser("user")
SomeWs_Request._setPassword("plain-password")

Valery Silaev

SaM Solutions

http://www.sam-solutions.net

Former Member
0 Kudos

Hi Valery

thanks for your answer. The problem is, that this is the demo Procurement scenario from the sap discovery system. And yet I don´t have access to the code. I only know, that the adobe form is presented via sap portal. I found the iview with the sales formular via portal content administration. But I'm not able to edit the object. But is this the right way to search for the code where the setUser is set. Another question is which user is the correct user which has the authorisation to create the salesorder. From the j2ee administrator log I get the message, that the user j2ee_guest is not authorized. Where is the connection between the user proc_sales and j2ee_guest?

In XI as far as I know the user PIAPPLUSER is used to route the message via soap adapter and abap proxy to the ERP System.

Who rejects the call ? Fact is, that in the RWB no message is incoming.

Regards Marlies

Former Member
0 Kudos

I found the solution on my own. Here it is

Goto VisualAdmin:

Select Cluster/Services/Destinations

Select Webservice

Select sap.com/XApps_XI_SO_WS_Proxy/com.sap.esadiscovery.so.wsproxy.XApps_XI_SO_WS_ProxyName/ESA_MI_SO_CREATE_WS_INPort

Change the Hostname in the following Custom URL to the right hostname: http://iwdfvm1127.wdf.sap.corp:51080/XISOAPAdapter/MessageServlet?channel=:WebService:GM_WS_SOAP_SEN...

In our case the correct hostname is iwdfvm2160.

Further set the authentication to basic and fill username with PIAPPLUSER and Password with the approriate password

regards Marlies