cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

java.io.IOException: Server returned HTTP response code: 401 for URL

Former Member
0 Likes
12,644

Hi,

Third part is getting the below error when invoking the webservice in XI

at java.lang.Thread.run(Thread.java:662)

Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL <URL LINK>

at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1441)

at java.net.URL.openStream(URL.java:1010)

at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.createReader(RuntimeWSDLParser.java:804)

at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.resolveWSDL(RuntimeWSDLParser.java:262)

at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:129)

This is not because of the invalid credentials. It was working before one month. Please suggest.

Thanks and Regards

Suma S

View Entire Topic
Shabarish_Nair
Active Contributor
0 Likes
Server returned HTTP response code: 401 for URL

This in any case points to a authorization issue.

if you are connecting to PI, check the user in PI. Is it locked or has the password expired?

If you are connecting to a 3rd party system, contact them

Former Member
0 Likes

Yes, I agree with Shabarish.

Http 401 error, refer to Unauthorized.

The request requires user authentication. The response MUST include a WWW-Authenticate header field (section 14.47) containing a challenge applicable to the requested resource. The client MAY repeat the request with a suitable Authorization header field (section 14.8). If the request already included Authorization credentials, then the 401 response indicates that authorization has been refused for those credentials. If the 401 response contains the same challenge as the prior response, and the user agent has already attempted authentication at least once, then the user SHOULD be presented the entity that was given in the response, since that entity might include relevant diagnostic information. HTTP access authentication is explained in "HTTP Authentication: Basic and Digest Access Authentication"

Check for User/Pass parameters in your call, and check if user is not locked.