Project

General

Profile

[2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring"

Added by Gerald Brandt almost 2 years ago

I keep getting a timeout in Wt. It happens randomly, sometimes it takes days, and sometimes only a few hours. I put in a global catch to see if Wt was throwing somewhere, and it doesn't seem to be. I also searched the forums and didn't see a solution.

Is there anything I can do to get rid of this timeout?

Gerald

[2022-Jun-12 10:01:38.683] 548181 - [info] "WebRequest: took 21.374 ms" 127.0.0.1 - - [2022-Jun-12 10:01:40.425] "POST /?wtd=w4tiG35IVTwkuG6k HTTP/1.1" 200 1278
[2022-Jun-12 10:01:40.425] 548181 - [info] "WebRequest: took 21.109 ms" 127.0.0.1 - - [2022-Jun-12 10:01:43.682] "POST /?wtd=eOK7lUHl8aNktuhR HTTP/1.1" 200 1282
[2022-Jun-12 10:01:43.682] 548181 - [info] "WebRequest: took 20.406 ms" 127.0.0.1 - - [2022-Jun-12 10:01:45.425] "POST /?wtd=w4tiG35IVTwkuG6k HTTP/1.1" 200 1280
[2022-Jun-12 10:01:45.425] 548181 - [info] "WebRequest: took 21.746 ms" 127.0.0.1 - - [2022-Jun-12 10:01:48.684] "POST /?wtd=eOK7lUHl8aNktuhR HTTP/1.1" 200 1281
[2022-Jun-12 10:01:48.684] 548181 - [info] "WebRequest: took 22.334 ms" 127.0.0.1 - - [2022-Jun-12 10:01:50.426] "POST /?wtd=w4tiG35IVTwkuG6k HTTP/1.1" 200 1277
[2022-Jun-12 10:01:50.426] 548181 - [info] "WebRequest: took 22.154 ms" 
[2022-Jun-12 10:01:52.769] 548181 [/ NfaNCAQAbX1KNtyH] [info] "WebController: timeout: expiring"
[2022-Jun-12 10:01:52.769] 548181 [/ haVcKbDRuq3hip3C] [info] "WebController: timeout: expiring"
exiting


Replies (8)

RE: [2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring" - Added by Korneel Dumon almost 2 years ago

Hi Gerald,

it's difficult to say just from these logs. I recently found an issue regarding a timeout for idle sessions: https://redmine.emweb.be/issues/10488
If your site has server-push enabled and uses multi-session cookies, this might be the issue.

Korneel

RE: [2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring" - Added by Gerald Brandt almost 2 years ago

I have no idea how to turn on or off server-push or multi-session cookies. I just started building from the examples, so I'm running whatever Wt defaults to.

Gerald

RE: [2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring" - Added by Korneel Dumon almost 2 years ago

Then it's probably unrelated. Server-push is when you call WApplication::enableUpdates() and multi-session cookies can be enabled in wt_config.xml.

RE: [2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring" - Added by Gerald Brandt almost 2 years ago

Does anyone have any ideas here? Wt crashing is not a good thing. It's not a throw, since I don't catch anything. How can I fix it?

Gerald

RE: [2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring" - Added by Roel Standaert almost 2 years ago

Are you noticing that your sessions suddenly time out, or are you just seeing this in your logs?

Wt sessions will time out if there has been no communication for 600 seconds (10 minutes) by default, though this can be changed in wt_config.xml.

When you close your browser tab the client side tries to send a request to the server side to notify that the tab was closed and the session can end, but whether or not that message is still sent is very much up to the browser. Those sessions will hang around until they eventually time out. Seeing those messages in the logs is very much part of normal Wt operation (hence the fact that they're logged with info log level). Sessions may also time out if the connection was cut for some other reason and wasn't reestablished within the timeout (e.g. the Internet connection was lost).

wtfcgi is legacy. I would very much discourage its use.

RE: [2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring" - Added by Gerald Brandt almost 2 years ago

I have a browser open to the application, and the server updates the display every 10 seconds or so, with a larger update (graphs) every 60 seconds. I am behind a reverse proxy, but the issue occurs even when I'm not.

The log goes to stderr, so I see the timeout on-screen followed by immediate application exit. It seems to be a clean exit, since my destructors are called.

I was using shared-sessions, so when Wt does the timeout, the application dies. I am now trying dedicated-sessions to see if that solves the issue.

Gerald

RE: [2022-Jun-09 09:17:45.802] 354038 [/ RDFUX6VX1tfxpJih] [info] "WebController: timeout: expiring" - Added by Harm ​ over 1 year ago

What browsers are you experiencing these timeouts with?

Chrome has been throttling JavaScript timers over the years:

If Chrome deems your JavaScript's CPU usage as too high, it could delay Wt's keepAlives, causing a timeout.

Maybe try disabling your large graph updates, and see if you still get timed out.

 
Harm.

    (1-8/8)