Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Time out errors #3

Closed
dmzx opened this issue Sep 28, 2016 · 8 comments
Closed

Time out errors #3

dmzx opened this issue Sep 28, 2016 · 8 comments

Comments

@dmzx
Copy link
Contributor

dmzx commented Sep 28, 2016

Got some members with time out errors:

Is this an Mchat error maybe? I'm getting it both here, and my own site.

knipsel

Also reported:

I feel we need to improve overall error handling before releasing.
Simple test:

  1. publish some message in chat, wait for it to appear
  2. disconnect internet, while keeping chat visible
    Outcome: you will get undefined error or timeout error in best case. Imo, we should not throw error in such situation, be consistent with phpBB behavior..

In logs:

jquery.min.js?assets_version=69:4 XHR finished loading: POST "http://www.sample.org/forum/mchat/action/refresh".send @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 jquery.min.js?assets_version=69:4 POST http://www.sample.org/forum/mchat/action/refresh net::ERR_NAME_NOT_RESOLVEDsend @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 jquery.min.js?assets_version=69:4 XHR failed loading: POST "http://www.sample.org/forum/mchat/action/refresh".send @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 mchat.js?assets_version=69:116 AJAX error. status: error, message: () jquery.min.js?assets_version=69:4 POST http://www.sample.org/forum/mchat/action/refresh net::ERR_INTERNET_DISCONNECTEDsend @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 jquery.min.js?assets_version=69:4 XHR failed loading: POST "http://www.sample.org/forum/mchat/action/refresh".send @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 mchat.js?assets_version=69:116 AJAX error. status: error, message: () jquery.min.js?assets_version=69:4 POST http://www.sample.org/forum/mchat/action/refresh net::ERR_INTERNET_DISCONNECTEDsend @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 jquery.min.js?assets_version=69:4 XHR failed loading: POST "http://www.sample.org/forum/mchat/action/refresh".send @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 mchat.js?assets_version=69:116 AJAX error. status: error, message: () jquery.min.js?assets_version=69:4 POST http://www.sample.org/forum/mchat/action/whois net::ERR_INTERNET_DISCONNECTEDsend @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86whois @ mchat.js?assets_version=69:324 jquery.min.js?assets_version=69:4 XHR failed loading: POST "http://www.sample.org/forum/mchat/action/whois".send @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86whois @ mchat.js?assets_version=69:324 mchat.js?assets_version=69:116 AJAX error. status: error, message: () undefined:1 Uncaught (in promise) DOMException: The play() request was interrupted by a call to pause(). jquery.min.js?assets_version=69:4 POST http://www.sample.org/forum/mchat/action/refresh net::ERR_INTERNET_DISCONNECTEDsend @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 jquery.min.js?assets_version=69:4 XHR failed loading: POST "http://www.sample.org/forum/mchat/action/refresh".send @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 mchat.js?assets_version=69:116 AJAX error. status: error, message: () jquery.min.js?assets_version=69:4 POST http://www.sample.org/forum/mchat/action/refresh net::ERR_INTERNET_DISCONNECTEDsend @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 jquery.min.js?assets_version=69:4 XHR failed loading: POST "http://www.sample.org/forum/mchat/action/refresh".send @ jquery.min.js?assets_version=69:4ajax @ jquery.min.js?assets_version=69:4ajaxRequest @ mchat.js?assets_version=69:86refresh @ mchat.js?assets_version=69:295 mchat.js?assets_version=69:116 AJAX error. status: error, message: ()

I have also experienced some logouts on my website, is the time out handled to quick maybe?

@kasimi
Copy link
Owner

kasimi commented Sep 28, 2016

The timeout is the same as the refresh interval as defined in the ACP, but not more than 10 seconds: https://github.com/kasimi/mChat/blob/2.0.0-RC6/styles/all/template/javascript/mchat.js#L88 I think 10 seconds is more than enough to allow a request to complete.

Is your refresh rate longer than 10 seconds? If not try to increase it.

I agree that a popup for timeout errors is too aggressive. I'll see if there's a way to suppress it in that case.

Can you elaborate on your problem with logouts? When do they happen? Are you sure they are related to mChat?

@dmzx
Copy link
Contributor Author

dmzx commented Sep 28, 2016

Will do some checking, it appears when disabling or purge cache it will take a long time to refresh the page.

@ghost
Copy link

ghost commented Sep 28, 2016

I have the same problem with rc6 in root but with the site cloned and in a folder no time outs no errors via popups when in root host cpu runs at 45% and i have turbo servers out of root perfect i put rc5 back on in root perfect.

kasimi added a commit that referenced this issue Sep 28, 2016

Verified

This commit was signed with the committer’s verified signature.
kasimi kasimi
@kasimi
Copy link
Owner

kasimi commented Sep 28, 2016

With the above linked change timeout and unknown errors (for example disconnected internet) won't display a popup any more. Note that this doesn't solve the cause of the problem, it's just a cosmetic fix.

@Martin123456 Interesting observation. All of my phpBB boards where mChat is installed run in a sub-directory so I haven't noticed anything out of the ordinary. I will test this in the root folder and report back.

Out of curiosity, what's your refresh interval? And when you saw the high CPU load:

  • how many users were online, i.e. reading the chat?
  • how many users were actively chatting?

@ghost
Copy link

ghost commented Sep 28, 2016

Refresh is 10 seconds there is never any more then 3 or 4 in chat

cpu is random in the image at the start of the day is rc5 you can see when rc6 went on lol

http://www.martins-homelinux.net/images/tempuploads/1475145728.png

RC6 is stable when in subdirectory site is heavy on ext's so cloned the site to subdirectory and perfect there

Edit: made the changes to mchat.js cpu has total drop and no time out errors left pc on went to bed got up and still in chat and working ok.

@kasimi
Copy link
Owner

kasimi commented Sep 29, 2016

Good to know about the timeout errors, but what do you mean by "cpu has total drop"? Did updating mchat.js make the CPU usage go back to normal?

@ghost
Copy link

ghost commented Sep 29, 2016

Yes all the way down to 11% massive drop i sat at 11% of cpu usage on rc5 too.

@kasimi
Copy link
Owner

kasimi commented Sep 29, 2016

I have no idea how that could have fixed it but I'm glad it's all good now, thanks for testing.

If you notice any problems with CPU load in the future feel free to open a new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants