Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

get IOException over Proxy  RSS feed

 
Mathias Andrae
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am new in socket programming.
I only want to receive a document from an URL.
Doing it in the intranet works fine. But doing it over the proxy from the WWW it gives an IOException.
I suppose the proxy is the cause for it.
Any idea what I have to do??
Here my simple source:
 
Karthik Banda
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Dear,
just include two more lines of code and try with it as below. As you are not thrown any Security Excpeption while doing this, there is no problem as such in using a proxy. But, may be this is the problem with your Buffer size on the network which may be causing this. so try with this..
try
{
URLConnection con=url.openConnection();
InputStream is=con.getInputStream();
/*
now pass this "is" into the constructor of BufferedReader and also give the buffer size say around 512
*/
}
and try with this and please let me know tyhe result at karthik@electricangels.com
Regards,
karthik
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!