Bug 58756 - Log duration of LDAP and Authorization operations
Summary: Log duration of LDAP and Authorization operations
Status: CLOSED FIXED
Alias: None
Product: UCS
Classification: Unclassified
Component: UDM (Generic)
Version: UCS 5.2
Hardware: Other Linux
: P5 normal
Target Milestone: UCS 5.2-3-errata
Assignee: Florian Best
QA Contact: Felix Botner
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-10-29 13:21 CET by Florian Best
Modified: 2025-11-05 14:26 CET (History)
0 users

See Also:
What kind of report is it?: ---
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Customer ID:
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Best univentionstaff 2025-10-29 13:21:24 CET
> The administrator wants a central place to collate all operations in one place, for further performance analysis.

The timing of all LDAP operations and all authorization requests should be logged on TRACE level with their duration.
The request ID is part of all log lines, so the logged events can be related to the corresponding operation (e.g. UDM Creation of an object).
Comment 1 Florian Best univentionstaff 2025-10-29 16:53:54 CET
The Structured log wrapper now provides a context manager method "timing" which can be used to log the duration, e.g:

>>> with log.timing('Message'):
...  import time
... 
2025-10-29T12:11:15.409133+00:00    TRACE [         -] Message  | pid=1953488 logname=ADMIN func=<stdin>.<module>:1 duration=0.000010

All LDAP operations and authorization operations are now logged in this way.

univention-python (15.3.1)
f9df968048a8 | feat(python): add logging of LDAP operation duration

univention-directory-manager-modules (17.3.5)
97025dfc94ea | feat(udm): add logging of authorization operation durations

univention-debug-python (14.3.2)
6b653e3061b5 | feat(debug): add log method to log duration of operations

univention-debug-python.yaml
6b653e3061b5 | feat(debug): add log method to log duration of operations
univention-directory-manager-modules.yaml
97025dfc94ea | feat(udm): add logging of authorization operation durations
univention-python.yaml
f9df968048a8 | feat(python): add logging of LDAP operation duration
Comment 2 Felix Botner univentionstaff 2025-11-05 10:21:58 CET
OK tests
OK advisory
OK univention-directory-manager-modules
OK univention-python