Skip to content

[3.13] gh-105623 Fix performance degradation in logging RotatingFileHandler (GH-105887) #121117

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 28, 2024

Conversation

miss-islington
Copy link
Contributor

@miss-islington miss-islington commented Jun 28, 2024

The check for whether the log file is a real file is expensive on NFS
filesystems. This commit reorders the rollover condition checking to
not do the file type check if the expected file size is less than the
rotation threshold.

(cherry picked from commit e9b4ec6)

Co-authored-by: Craig Robson [email protected]
Co-authored-by: Oleg Iarygin [email protected]

…ndler (pythonGH-105887)

The check for whether the log file is a real file is expensive on NFS
filesystems.  This commit reorders the rollover condition checking to
not do the file type check if the expected file size is less than the
rotation threshold.

(cherry picked from commit e9b4ec6)

Co-authored-by: Craig Robson <[email protected]>
Co-authored-by: Oleg Iarygin <[email protected]>
@miss-islington miss-islington requested a review from vsajip as a code owner June 28, 2024 08:52
@serhiy-storchaka serhiy-storchaka enabled auto-merge (squash) June 28, 2024 08:53
@serhiy-storchaka serhiy-storchaka merged commit e310d2b into python:3.13 Jun 28, 2024
35 checks passed
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.

3 participants