This is an archived forum post. The information may be outdated. Contact us if you have any questions.

PdfcrowdError java.net.SocketTimeoutException: Timeout while fetching URL: http://pdfcrowd.com:80/api/pdf/convert/html/

freightos wrote on 2013-02-07:
Suddenly getting this exception with every call to convertHtml()

Please help!

Thanks
support wrote on 2013-02-07:
According to our records a PDF file is created on our server but your client prematurely closes the connection after a few seconds without waiting for the response.

Have you made any changes to your system/configuration recently?
freightos wrote on 2013-02-07:
No changes. We are calling your convertHtml() function same as we always did. In fact it was working fine yesterday and we made no changes at all to our system since then.
support wrote on 2013-02-07:
Please can you try now and let me know if it works?
freightos wrote on 2013-02-07:
Yes it does - thanks for the quick support!
support wrote on 2013-02-07:
It turned out that our network was experiencing an issue with increased latency. The issue was related to network maintenance performed by our hosting provider. The issue is fully resolved now.

Tip: We noticed that you are on AppEngine. To make your application more resistant against this kind of issues we recommend to increase the default 5 seconds AppEngine deadline for requests.

According to the URL Fetch Java API docs: "You can set a deadline for a request, the most amount of time the service will wait for a response. By default, the deadline for a fetch is 5 seconds. The maximum deadline is 60 seconds for HTTP ..."
hammam wrote on 2013-08-15:
If that is the issue then you guys should modify the URLConnection in your Java API pdfcrowd.jar by increasing the connection timeout limit to be at least 60 secs for example. Since the API is responsible of creating the connection.
More specifically in com.pdfcrowd.Client.getConnection(String, String)
com.pdfcrowd.Client.getConnection(String, String) {
      ...
      conn.setConnectTimeout(60000);
      ...
}
support wrote on 2013-08-17:
Hello,

Thanks for the feedback. We are already aware of this issue and will update the client library in the coming days.
mahendra158 wrote on 2015-11-19:
Hi Team

I am getting connection timed out error . I checked client.java in which getconnection time is set 120000 bydefault.kindly do needfull to overcome this problem.

Thanks and Regards
Mahendra kumar sahu