Skip to content

[feat] make min-reserved-fds configurable at runtime - #460

Open
qiongtubao wants to merge 1 commit into
mainfrom
feature/dynamic_change_min_reserved_fds
Open

qiongtubao wants to merge 1 commit into
mainfrom
feature/dynamic_change_min_reserved_fds

Conversation

@qiongtubao

Copy link
Copy Markdown

Move the FD-budget raise logic into raiseOpenFilesLimit() so that both maxclients and min-reserved-fds share the same runtime callback. The shared updateOpenFilesLimit() recomputes the event-loop setsize from both values, raises RLIMIT_NOFILE when needed, and resizes the ae event loop. Rollback is handled by the existing configs framework.

Cover the new behavior with unit tests in tests/unit/limits.tcl and drop min-reserved-fds from the immutable skip list in tests/unit/introspection.tcl.

@qiongtubao
qiongtubao force-pushed the feature/dynamic_change_min_reserved_fds branch 4 times, most recently from 28de44b to 5122344 Compare October 28, 2026 12:19
Move the FD-budget raise logic into raiseOpenFilesLimit() so that both
maxclients and min-reserved-fds share the same runtime callback. The
shared updateOpenFilesLimit() recomputes the event-loop setsize from
both values, raises RLIMIT_NOFILE when needed, and resizes the ae event
loop. Rollback is handled by the existing configs framework.

Cover the new behavior with unit tests in tests/unit/limits.tcl and
drop min-reserved-fds from the immutable skip list in
tests/unit/introspection.tcl.
@qiongtubao
qiongtubao force-pushed the feature/dynamic_change_min_reserved_fds branch from 5122344 to f0c8f1e Compare October 28, 2026 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant