Repository navigation
[backport stable-8.1] feat(graph): allow disabling the last sign-in timestamp update - #12531
Conversation
…oud#12522) * feat(graph): [OCISDEV-1022] allow disabling last sign-in timestamp update Add a new setting OCIS_LDAP_UPDATE_LAST_SIGNIN_DATE / GRAPH_LDAP_UPDATE_LAST_SIGNIN_DATE (default true) to disable maintaining the 'oCLastSignInTimestamp' LDAP attribute on user sign-in. When set to false the graph service no longer listens for UserSignedIn events and does not write the attribute, without having to disable all LDAP writes or the events consumer. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]> * docs(changelog): [OCISDEV-1022] fix PR link to 12522 Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]> * test(graph): [OCISDEV-1022] cover last sign-in toggle; address review - Add unit test covering both branches of StartListenForLogonEvents (subscribes when UpdateUserLastSignInDate is enabled, not when disabled). - Set introductionVersion to 8.2.0. - Reword the config description: the two settings are independent, the timestamp is only persisted when OCIS_LDAP_SERVER_WRITE_ENABLED is enabled rather than the toggle requiring it. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]> --------- Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]> Co-authored-by: Martin <[email protected]> (cherry picked from commit 49c897e)
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
dj4oC
left a comment
There was a problem hiding this comment.
Backports the "allow disabling the last sign-in LDAP timestamp write" flag (#12522) to stable-8.1.
Findings
Same change as #12532 (backport to stable-8.0), clean cherry-pick. Security/Stability/Performance: no findings — gates the existing UserSignedIn LDAP write behind a new opt-out flag, default true preserves current behavior. Test coverage: logon_events_test.go covers both flag states. TODOs found: none. Dependency touched: no.
Unlike its stable-8.0 sibling (#12532), all checks are green on this PR's head commit (e80536b), including all-acceptance-tests.
Deployment topology check
Compatible — per-service Go config flag, no topology-specific assumptions.
Verdict
Approved.
🤖 Automated review by Claude Code (security · stability · performance · coverage)
Generated by Claude Code
Generated by Claude Code |
Backport of #12522 to
stable-8.1.Adds
OCIS_LDAP_UPDATE_LAST_SIGNIN_DATE/GRAPH_LDAP_UPDATE_LAST_SIGNIN_DATE(defaulttrue) to let operators stop the graph service from writing theoCLastSignInTimestampLDAP attribute on every sign-in, reducing LDAP write load.When set to
false, the graph service no longer subscribes toUserSignedInevents and does not write the attribute.UserSignedInis the only event this listener handles, so gating the whole listener has no other side effects.Notes on the backport
-x); git's 3-way merge applied theservice.gogate onto the stable-8.1 variant ofStartListenForLogonEvents(which lacks the master-only trace span wiring).introductionVersionadjusted from8.2.0(master) to8.1.1to reflect the stable-8.1 release line.Original PR: #12522
🤖 Generated with Claude Code