Skip to content
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

reduce memory required for logmon, docker_logger and executor processes #6341

Merged
merged 2 commits into from
Sep 18, 2019

Conversation

nickethier
Copy link
Member

The init() funcs in each of these packages checks the cli args and runs the processes before ever hitting the main cli run logic. If we load these packages first then it stops additional packages form ever getting a chance to be imported thus saving some memory overhead. On my machine this reduced the RSS by ~10MB for these processes.

@nickethier nickethier added this to the 0.10.0 milestone Sep 17, 2019
Copy link
Contributor

@notnoop notnoop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome - Great catch!

@@ -9,8 +9,11 @@ import (
"strings"
"text/tabwriter"

_ "github.com/hashicorp/nomad/client/logmon"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add a comment explaining these lines and their utility?

@nickethier nickethier merged commit 404d2d4 into master Sep 18, 2019
@nickethier nickethier deleted the b-plugin-proc-bloat branch September 18, 2019 03:55
notnoop pushed a commit that referenced this pull request Sep 19, 2019
* reduce memory required for logmon, docker_logger and executor processes

* comment early importing
@github-actions
Copy link

I'm going to lock this pull request because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 30, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants