Summary
The global idle-time-limit setting (cn=config) has no effect: idle client connections are never disconnected, no matter what the option is set to. Only the per-user ds-rlim-idle-time-limit attribute works.
Steps to reproduce
-
Set a global idle time limit:
dsconfig set-global-configuration-prop --set idle-time-limit:"10 s" ...
(or put it in the configuration before startup)
-
Open an LDAP connection (anonymous or bound) and let it sit idle past the limit.
Expected: the server disconnects the connection with the notice of disconnection DISCONNECT reason="Idle Time Limit Exceeded".
Actual: the connection stays open forever.
Root cause
CoreConfigManager parses the setting into its private CoreAttributes, which nothing reads back. New client connections snapshot the limit from DirectoryServer.getIdleTimeLimit() (ClientConnection constructor, also LocalBackendBindOperation), but the backing field is initialized to 0 and DirectoryServer.setIdleTimeLimit() has no callers — so every connection carries idleTimeLimit=0 (disabled) regardless of the configuration, at startup and after dynamic dsconfig changes alike. IdleTimeLimitThread runs, but has nothing to enforce.
How it was found
Running the slow TestNG group (excluded from CI): both server-wide IdleTimeLimitTestCase tests time out after 60s because idle connections are never disconnected.
Summary
The global
idle-time-limitsetting (cn=config) has no effect: idle client connections are never disconnected, no matter what the option is set to. Only the per-userds-rlim-idle-time-limitattribute works.Steps to reproduce
Set a global idle time limit:
(or put it in the configuration before startup)
Open an LDAP connection (anonymous or bound) and let it sit idle past the limit.
Expected: the server disconnects the connection with the notice of disconnection
DISCONNECT reason="Idle Time Limit Exceeded".Actual: the connection stays open forever.
Root cause
CoreConfigManagerparses the setting into its privateCoreAttributes, which nothing reads back. New client connections snapshot the limit fromDirectoryServer.getIdleTimeLimit()(ClientConnectionconstructor, alsoLocalBackendBindOperation), but the backing field is initialized to0andDirectoryServer.setIdleTimeLimit()has no callers — so every connection carriesidleTimeLimit=0(disabled) regardless of the configuration, at startup and after dynamicdsconfigchanges alike.IdleTimeLimitThreadruns, but has nothing to enforce.How it was found
Running the
slowTestNG group (excluded from CI): both server-wideIdleTimeLimitTestCasetests time out after 60s because idle connections are never disconnected.