Hi Lads,
I'm guessing this question must be obvious to most people but really, I've
looked for an answer every where since like a week and still can't figure
out what's going on.
I'm simply trying to fetch a url from app engine. The response takes
approximately 6seconds to come back. Hence I'm trying to increase the url
connection timeout to something like 9seconds. However any settings I
specify to increase the timeout values seems to be ignored. I keep getting
an IOException at around 5seconds.
I initially thought maybe this was due to not using the lastest version of
app engine hence I upgraded to 1.5.3 but I'm still getting this exception at
5seconds.
This is killing me at this stage ! I would really appreciate any advice. I
must be doing something wrong but I can't figure out what it is.
I've tried setting the timeout with openConnection or with the URLFetch
service without any luck.
Here is the code I'm currently using:
URL url = new URL(urlRequest);
url.openConnection().setReadTimeout(9000);
url.openConnection().setConnectTimeout(9000);
URLFetchService fetcher = URLFetchServiceFactory.getURLFetchService();
HTTPResponse response1 = fetcher.fetch(url);
System.out.println("Response: "+new String(response1.getContent()));
--
You received this message because you are subscribed to the Google Groups
"Google App Engine for Java" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/google-appengine-java/-/wadjajVQoGMJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-appengine-java?hl=en.