This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
when i try to call the getInputStream() method I am getting the error as below:
Caused by: java.io.FileNotFoundException: Response: '401: Unauthorized' for url: 'xxxxxxxxxxxxx'
Please suggest me what would be the route cause for the below issue.
You might have some authentication mechanism in place on your weblogic. Unless you pass username and password it won't allow you to request.
You may as well want to check out Apache HTTPClient APIs for HTTP interaction. It makes it lot easier to do such things.
Joined: Mar 03, 2011
I am giving the username and password in the connection and i am getting the connection successfully
But when i try to execute the line InputStreamReader isr = new InputStreamReader(httpConn.getInputStream()); , I am getting the error.
When i execute the same java class in stand alone it is working fine.
But when i try from weblogic server i am facing the error.