WebApp closes by itself

  1. ‹ Older
  2. 4 days ago

    Alexandre C

    Feb 19 Pre-Release Testers, Xojo Pro

    @olivier v The problematic version is 2017.R3?

    No, it's not. I moved from a host provider to another about 3 years. Since then, i have this problem.

    I never worried about this, since all users of the application were windows.

    unfortunately, or not, my last application is focused on mac users, and everyone is having this problem.

    this is the reason why I am really and incessantly seeking a solution!

  3. Greg O

    Feb 19 Xojo Inc Somewhere near Raleigh, NC

    Boy I really wish we'd done this sooner. Now that I've seen your app and explanation, I've got a much clearer understanding about what you are experiencing. Some observations:

    The whole app isn't closing, right? Just the Sessions where a mac is connected?

    Looking at my browser (a mac), I'm getting 504 Gateway Timeout responses from the server. That means that the app or the web server isn't responding to the browser quickly enough. That said, my browser is still connected to the test app after 30 minutes

    We need a few more details about what your mac users are experiencing.
    First of all, which browser are they using? Safari, Chrome, Firefox, Opera, something else?
    Do you have any screen recordings of this problem they are having?

  4. Alberto D

    Feb 19 Pre-Release Testers, Xojo Pro

    Alexandre, I opened the url on Safari, Firefox and Chrome and I don't see it closing after 20 minutes or so.

    I reloaded the page and I don't see anything with Safari or Chrome, but I see this with Firefox (for a split second):
    -image-

    I hope it helps.

  5. Derk J

    Feb 19 Pre-Release Testers, Xojo Pro

    Your app has errors;

    session.LoadTable Error (2): SystemLoginContainerControl.FieldUserCode.LostFocus_1
    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND UserCode=''' at line 1(True)

    SELECT ID, Initialised FROM SYSTEMUSER WHERE AccountID= AND UserCode=''

  6. Alexandre C

    Feb 19 Pre-Release Testers, Xojo Pro

    @Greg OLone Boy I really wish we'd done this sooner. Now that I've seen your app and explanation, I've got a much clearer understanding about what you are experiencing. Some observations:

    The whole app isn't closing, right? Just the Sessions where a mac is connected?

    Looking at my browser (a mac), I'm getting 504 Gateway Timeout responses from the server. That means that the app or the web server isn't responding to the browser quickly enough. That said, my browser is still connected to the test app after 30 minutes

    We need a few more details about what your mac users are experiencing.
    First of all, which browser are they using? Safari, Chrome, Firefox, Opera, something else?
    Do you have any screen recordings of this problem they are having?

    Safari
    Didn't test on Chrome and Firefox

    movie

  7. Alexandre C

    Feb 19 Pre-Release Testers, Xojo Pro

    @Derk J Your app has errors;

    this app i used for example, does not call mysql at all

  8. olivier v

    Feb 19 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).

  9. Alexandre C

    Feb 19 Pre-Release Testers, Xojo Pro

    Ok. Great!

    So what's the solution / fix for this?

    I really don't know what to do.

    Alex

  10. Tony L

    Feb 19 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.

  11. 3 days ago

    Alexandre C

    Feb 20 Pre-Release Testers, Xojo Pro

    @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!

  12. Greg O

    Feb 20 Xojo Inc Somewhere near Raleigh, NC

    @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).

  13. Greg O

    Feb 20 Xojo Inc Somewhere near Raleigh, NC

    @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.

  14. Tobias B

    Feb 20 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.

  15. Tobias B

    Feb 20 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
  16. Tony L

    Feb 20 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?

  17. olivier v

    Feb 20 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

  18. Alexandre C

    Feb 20 Pre-Release Testers, Xojo Pro
    Edited 3 days ago

    @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!

  19. Alexandre C

    Feb 20 Pre-Release Testers, Xojo Pro

    @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?

  20. 2 days ago

    Greg O

    Feb 21 Xojo Inc Somewhere near Raleigh, NC

    @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.

  21. Alexandre C

    Feb 21 Pre-Release Testers, Xojo Pro

    @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

or Sign Up to reply!