Bug 45307 - umc/module/timeout has no effect anymore
umc/module/timeout has no effect anymore
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: UMC (Generic)
UCS 4.2
Other Linux
: P5 normal (vote)
: UCS 4.2-2-errata
Assigned To: Florian Best
Alexander Kläser
:
Depends on: 44965
Blocks:
  Show dependency treegraph
 
Reported: 2017-08-31 13:31 CEST by Florian Best
Modified: 2017-09-06 17:10 CEST (History)
6 users (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 7: Crash: Bug causes crash or data loss
Who will be affected by this bug?: 5: Will affect all installed domains
How will those affected feel about the bug?: 3: A User would likely not purchase the product
User Pain: 0.600
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Ticket number:
Bug group (optional): Workaround is available
Max CVSS v3 score:


Attachments
patch (1.85 KB, patch)
2017-08-31 13:31 CEST, Florian Best
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Best univentionstaff 2017-08-31 13:31:00 CEST
Created attachment 9160 [details]
patch

Since Bug #44965 the UMC module timeout of 600 seconds is not effective anymore if there are no active/pending requests.
Instead the connection timeout of 30 seconds stops the module process prior.
This shouldn't be a problem in the real world but the configuration is useless then.

Additionally if a request takes longer than 30 seconds, then after the response is send to the client the module process closes/ends immediately. This might be more a problem if e.g. the module process expects that after that request another request comes which needs data from the current module process.
I think we should evaluate the connection timeout after the response instead of at the start of the request.

Attached is a patch which fixes both problems.
Note: For Bug #44965 the connection timeout is only needed for the connection between UMC-Webserver and UMC-Server, not between UMC-Server and UMC-Moduleprocess.

+++ This bug was initially created as a clone of Bug #44965 +++

After opening many umc-modules I was not able to login to the umc anymore. I got a traceback (see screenshot.png).

Restarting the webserver solved the problem.
Comment 1 Florian Best univentionstaff 2017-08-31 13:33:22 CEST
@Dirk: This might also be the problem why two of the App-Center UMC Jenkins tests are currently failing:
http://jenkins.knut.univention.de:8080/job/UCS-4.2/job/UCS-4.2-1/job/AutotestJoin/lastCompletedBuild/SambaVersion=s4,Systemrolle=backup/testReport/20_appcenter/79_umc_broken_failure_error_exit_code/test/
Comment 2 Florian Best univentionstaff 2017-09-01 12:58:48 CEST
Workaround: ucr set 'umc/server/connection-timeout'=600
Comment 3 Florian Best univentionstaff 2017-09-01 13:09:08 CEST
univention-management-console (9.0.80-65):
r82577 | Bug #45307: fix umc/module/timeout

Merge to UCS 4.2-2:
r82579 | Bug #45307: fix umc/module/timeout

univention-management-console.yaml:
r82580 | YAML Bug #45307
Comment 4 Alexander Kläser univentionstaff 2017-09-01 14:36:40 CEST
Changes: OK
* The intended behaviour for Bug 44965 that inactive connections are cleaned up
  still works correctly.
* The timeout for module processes is respected properly.

YAML file: OK

→ VERIFIED
Comment 5 Alexander Kläser univentionstaff 2017-09-01 14:39:53 CEST
BTW ... please commit also these changes to 4.2-2!
Comment 6 Florian Best univentionstaff 2017-09-01 15:12:20 CEST
See comment #3, there is the merge mentioned.
Comment 7 Alexander Kläser univentionstaff 2017-09-01 15:34:36 CEST
OK
Comment 8 Alexander Kläser univentionstaff 2017-09-04 12:44:16 CEST
I cherry-picked and built the package for the 4.2-2 scope.
Comment 9 Alexander Kläser univentionstaff 2017-09-05 13:16:13 CEST
As the package had been built for the 4.2-2 scope, I added an entry to the changelog.

changelog-4.2-2.xml:
r82667 | Bug #45307, Bug #45280: added changelog entry
Comment 10 Arvid Requate univentionstaff 2017-09-06 17:10:12 CEST
<http://errata.software-univention.de/ucs/4.2/159.html>