Unable to setup a subscription because of timeouts



  • Dear developers and community,

    I’ve been using DavX5 for a while already and I really appreciate your work on this amazing app. Thumbs up for the open source concept and for having it in the F-Droid repos!
    With a new job I need to subscribe to a ICS calendar (pretty big one with a slow server unfortunately) and was happy to find ICSx5 in F-Droid. Actually it seems to be the only app in there for ICS subscriptions…
    My problem is now: I can’t really subscribe to the calendar because the responses of the server take too long and the app only gives timeouts. A quick test with curl on my pc revealed that the response takes approx. 60 seconds to arrive.
    Is there a way to change the time before timeout on my android or may it be possible to increase the standard timeout of the app in an update?

    I’d appreciate any help with this.
    Amo



  • 60 seconds to fetch a calendar is absolutely too slow. I would first contact the administrator of the server and report the problem to him. Very often the server is misconfigured or need to be updated to deliver acceptable results.



  • I reached out to an administrator and was told that the server is not really slow but has to put together the calendar live from different sources, which takes up some time. Still, he activated caching for me and the response time (as per tests with curl) got reduced to around 20 seconds.
    Now the app was able to subscribe after a few tries, but still most of the automatic attempts to sync fail with a timeout notification. It also seems to me that manual sync attempts have a higher success rate than the automatic ones, but not sure if it was just luck…
    I think I read that the timeout of the app is set to 45 seconds but it looks to me as if it was 20 seconds. What is the case?



  • Unfortunately, I am still getting timeout notifications on my automatic sync attempts. The response time of the server has been reduced to 20 seconds, which should hopefully be fine now. Is there something else I can check or do?


  • developer

    Until now, the read timeout was 30 seconds. In my opinion, a server shouldn’t require 30 seconds or more to send a reply.

    1. However, I have incread ICSx5 timeout to 60 seconds.
    2. I suggest to change the server so that it prepares your results in background and then just delivers them when requested.

    I have sent an APK with 60 seconds to your email address. Can you tell me whether it’s working for you?



  • Thank you very much for your help!

    Yes, with the APK you sent to me, it is working fine!

    I noticed that the app takes much longer to retrieve the calendar than curl on my desktop. Where curl takes between 15 and 20 seconds, the app takes around 30 seconds, which is probably why it ran into timeouts a lot.

    2: I think this is what the server admin meant when I got told that caching has been activated for me.


  • developer

    @amo said in Unable to setup a subscription because of timeouts:

    Thank you very much for your help!

    Yes, with the APK you sent to me, it is working fine!

    Perfect. Will be included in the next version.

    I noticed that the app takes much longer to retrieve the calendar than curl on my desktop. Where curl takes between 15 and 20 seconds, the app takes around 30 seconds, which is probably why it ran into timeouts a lot.

    I think this is because ICSx⁵ takes a few seconds to process the file. So the 20 seconds are probably the same, but a few seconds are needed for processing before ICSx⁵ updates the “last synced” field.

    2: I think this is what the server admin meant when I got told that caching has been activated for me.

    Are you sure? Caching sounds like “file is cached (and will be served from cache immediately) for some time, but as soon as the file is expired, it will be calculated at the next call (and take 20 secs again)”.


Log in to reply