WebApp closes by itself

  1. ‹ Older
  2. last year

    olivier v

    19 Feb 2018 Pre-Release Testers, Xojo Pro Europe (France)

    @Alexandre C

    Same observation as Greg. On my Mac (10.12.6), safari and firefox (http://alemac.com.br/cgi-bin/test/test.cgi ), the web app doesn't quit, but the browser can't communicate properly with the Xojo server app (all Xojo push requests have a 504 error).

  3. Alexandre C

    19 Feb 2018 Pre-Release Testers Brazil

    Ok. Great!

    So what's the solution / fix for this?

    I really don't know what to do.

    Alex

  4. Tony L

    19 Feb 2018 Pre-Release Testers, Xojo Pro Hong Kong

    Sorry for late reply as it was Chinese New Year holiday here....

    https://drive.google.com/open?id=1gItUPkdQ_bKZh2CHTnSA8Re4AZxUFcke

    This is the screen cap of the console when running my app in debug mode. I startup my app, didn't type anything (login details grabbed from cookie), let it stand still. After a minute or 2, the event "push" coming out and seems it cannot be finished, then keep trying. In deploy mode, there is another "ping" action but it does successfully. Just wondering if this cause the timeout for the app thus lead to app crash.

  5. Alexandre C

    20 Feb 2018 Pre-Release Testers Brazil

    @Tony L Sorry for late reply as it was Chinese New Year holiday here....

    https://drive.google.com/open?id=1gItUPkdQ_bKZh2CHTnSA8Re4AZxUFcke

    This is the screen cap of the console when running my app in debug mode. I startup my app, didn't type anything (login details grabbed from cookie), let it stand still. After a minute or 2, the event "push" coming out and seems it cannot be finished, then keep trying. In deploy mode, there is another "ping" action but it does successfully. Just wondering if this cause the timeout for the app thus lead to app crash.

    I saw this push event somewhere on my logs or erros, or somewhere but i can't remember where!

  6. Greg O

    20 Feb 2018 Xojo Inc

    @olivier v @Alexandre C

    Same observation as Greg. On my Mac (10.12.6), safari and firefox (http://alemac.com.br/cgi-bin/test/test.cgi ), the web app doesn't quit, but the browser can't communicate properly with the Xojo server app (all Xojo push requests have a 504 error).

    Olivier, please confirm that it’s all push requests. On my side, it was one out of 10 and the app kept working. FWIW, This behavior is expected once in a while (although I’ve never seen it like this).

  7. Greg O

    20 Feb 2018 Xojo Inc

    @Tony L Sorry for late reply as it was Chinese New Year holiday here....

    https://drive.google.com/open?id=1gItUPkdQ_bKZh2CHTnSA8Re4AZxUFcke

    This is the screen cap of the console when running my app in debug mode. I startup my app, didn't type anything (login details grabbed from cookie), let it stand still. After a minute or 2, the event "push" coming out and seems it cannot be finished, then keep trying. In deploy mode, there is another "ping" action but it does successfully. Just wondering if this cause the timeout for the app thus lead to app crash.

    Ok, first of all, we need to stop referring the this as a crash. A crash would mean that the app is quitting (or being forced to quit) and all of the connected users are being disconnected at the same time. That’s not what Alexandre is describing here. It’s simply not responding properly to certain users.

    As for the 504 Gateway Timeout error, this HTTP error is not generated by the Xojo app itself. It’s created by the web server in front of the cgi app in cases where it isn’t getting a response fast enough. This can happen under several circumstances:

    1. The app is crashing during the request (not what’s happening here)
    2. The app is in a tight loop and too busy to respond (also not what’s happening here because it’s an empty app)
    3. Too many users. It could be this... cgi apps can only handle about 50 simultaneous users.
    4. A web server configuration issue. While unlikely, it could simply be that the requests are being misrouted.
    5. A framework bug. I’m not expecting this to be the case or the problem would be more widespread, but it could be that the app can’t respond for some reason.

    What I need next is to know the country and language of the users who are having trouble so we can see if this is some sort of regional encoding issue.

  8. Tobias B

    20 Feb 2018 Pre-Release Testers, Xojo Pro Bern, Switzerland

    When I test the link to the remote server @Alexandre Cunha has provided with Safari 11.0.3 on 10.12.6 it with the, it seems to affect _all_ push requests. As these are long polling AJAX requests, a delayed response is expected. The CGI seems to sit behind an Apache. That, together with the log excerpt from the OP let me think of an Timeout for CGI requests configured within the Apache.

  9. Tobias B

    20 Feb 2018 Pre-Release Testers, Xojo Pro Bern, Switzerland

    @Greg OLone What I need next is to know the country and language of the users who are having trouble so we can see if this is some sort of regional encoding issue.

    I tried it from Europe, Switzerland with an Accept-Language of de-ch. All Push requests get an 504 Error after 40.3 sec. Posts to Ping-Requests on the other side can span 137sec but I understand these are delayed while sending not receiving.

    CURL-extracted samples:

    $ time curl 'http://alemac.com.br/cgi-bin/test/test.cgi/4D08D700E876726DF30072FAB4918E6B5ED63CD0/comm/push' \
    > -XPOST \
    > -H 'Referer: http://alemac.com.br/cgi-bin/test/test.cgi' \
    > -H 'Content-Type: application/x-www-form-urlencoded' \
    > -H 'Origin: http://alemac.com.br' \
    > -H 'Host: alemac.com.br' \
    > -H 'Accept: */*' \
    > -H 'Connection: keep-alive' \
    > -H 'Accept-Encoding: gzip, deflate' \
    > -H 'Accept-Language: de-ch' \
    > -H 'DNT: 1' \
    > -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/604.5.6 (KHTML, like Gecko) Version/11.0.3 Safari/604.5.6' \
    > -H 'Content-Length: 0' \
    > -H 'Cache-Control: no-cache'
    <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
    <html><head>
    <title>504 Gateway Timeout</title>
    </head><body>
    <h1>Gateway Timeout</h1>
    <p>The gateway did not receive a timely response
    from the upstream server or application.</p>
    <p>Additionally, a 504 Gateway Timeout
    error was encountered while trying to use an ErrorDocument to handle the request.</p>
    </body></html>
    
    real	0m40.351s
    user	0m0.007s
    sys	0m0.008s

    and

    $ time curl 'http://alemac.com.br/cgi-bin/test/test.cgi/4D08D700E876726DF30072FAB4918E6B5ED63CD0/comm/ping' \
    > -XPOST \
    > -H 'Referer: http://alemac.com.br/cgi-bin/test/test.cgi' \
    > -H 'Content-Type: application/x-www-form-urlencoded' \
    > -H 'Origin: http://alemac.com.br' \
    > -H 'Accept: */*' \
    > -H 'Cache-Control: no-cache' \
    > -H 'DNT: 1' \
    > -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/604.5.6 (KHTML, like Gecko) Version/11.0.3 Safari/604.5.6'
    {"jsSource":"Xojo.comm.begin();"}
    real	0m0.481s
    user	0m0.006s
    sys	0m0.005s
  10. Tony L

    20 Feb 2018 Pre-Release Testers, Xojo Pro Hong Kong

    @Greg OLone I think my problem is different from Alexandre’s one as my app is really shutting down with all connected users being kicked out. I am not sure if we need to separate this thread into 2 for separate discussion.

    Greg, you have mentioned that cgi has a limitation on 50 concurrent users, does standalone app have the same limitation?

  11. olivier v

    20 Feb 2018 Pre-Release Testers, Xojo Pro Europe (France)

    @Greg OLone In the case of Alexandre, I thought exactly the same as Tobias. All push requests failed after 40 seconds. Like Tobias, I try from Europe (France). @Alexandre C , can you send your Apache configuration file (httpd. conf) please?

    Safari
    https://www.dropbox.com/s/8jomajf97aaav5f/xojoAlexSafari.png?dl=0

    Chrome
    https://www.dropbox.com/s/i9p5vh7h1rf1l9h/xojoAlexChrome.png?dl=0

  12. Alexandre C

    20 Feb 2018 Pre-Release Testers Brazil
    Edited last year

    @Greg OLone Ok, first of all, we need to stop referring the this as a crash. A crash would mean that the app is quitting (or being forced to quit) and all of the connected users are being disconnected at the same time. That’s not what Alexandre is describing here. It’s simply not responding properly to certain users.

    Correct!

    @Greg OLone Too many users. It could be this... cgi apps can only handle about 50 simultaneous users.

    In my webapp, it's not the case. There are only 8 or at most 10 simultaneous users.

    @Greg OLone What I need next is to know the country and language of the users who are having trouble so we can see if this is some sort of regional encoding issue.

    I'm from Brazil. I use all in English: MacOS, Xojo, Browsers, etc.
    The same for dates, numbers, etc

    One big problem i have and reported before, is about localization: Feedback #40624 - Localization of number does not work
    On my app i need to do some workarounds to fix this. But also it's not the case here, since we are using a "test.app" with no code at all.

    Tell me if you need more information!

  13. Alexandre C

    20 Feb 2018 Pre-Release Testers Brazil

    @olivier v can you send your Apache configuration file (httpd. conf) please?

    The full file? I have 10+ sites on my server…

    what information do you need exactly?

  14. Greg O

    21 Feb 2018 Xojo Inc

    @Alexandre C – Could you start a new thread for your issue? I can’t keep the two conversations straight. Once you do that, I’ll try to extract your portion of this conversation over there.

  15. Alexandre C

    21 Feb 2018 Pre-Release Testers Brazil

    @Greg OLone @Alexandre C – Could you start a new thread for your issue? I can’t keep the two conversations straight. Once you do that, I’ll try to extract your portion of this conversation over there.

    Done

  16. Tony L

    2 Mar 2018 Pre-Release Testers, Xojo Pro Answer Hong Kong

    Just an update to the status of my "problem". It is in fact my own fault, every time I compiled the project, I only copied the main program without the others. Now I copied everything to the server every time I deploy a new version, it seems to work without problem now. Sorry for my stupid mistake and many thanks to all your suggestions made in this thread.

  17. Alexandre C

    7 Mar 2018 Pre-Release Testers Brazil

    @Tony L Just an update to the status of my "problem". It is in fact my own fault, every time I compiled the project, I only copied the main program without the others. Now I copied everything to the server every time I deploy a new version, it seems to work without problem now. Sorry for my stupid mistake and many thanks to all your suggestions made in this thread.

    Hi @Greg OLone, I do the same thing!

    But i also uploaded all components and the problem persists.

    Alex

  18. Tony L

    7 Mar 2018 Pre-Release Testers, Xojo Pro Hong Kong

    @Alexandre C part of the components may be held up by Linux, try stopping Apache and make sure no files are being held up, then copy

  19. Alexandre C

    7 Mar 2018 Pre-Release Testers Brazil

    @Tony L @Alexandre C part of the components may be held up by Linux, try stopping Apache and make sure no files are being held up, then copy

    @Tony L, already did it.

    Same thing

  20. Tony L

    7 Mar 2018 Pre-Release Testers, Xojo Pro Hong Kong

    @Alexandre C I am not sure if this relates to your problem, I now deploy my apps on a Mac instead of windows. No matter web apps or desktop apps, if I use my windows 10 machine to deploy, abnormal errors or app crash appears.

  21. Alexandre C

    10 Mar 2018 Pre-Release Testers Brazil

    I changed Apache timeout from 20 to 300 seconds. Same problem!

or Sign Up to reply!