-
Notifications
You must be signed in to change notification settings - Fork 42
Warn when productivity is low #2005
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
Warn when productivity is low #2005
Conversation
ana-pantilie
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to use the logger to issue a warning for this?
That would require |
|
|
Oh, I thought by "logger" you mean the entire logging mechanism. @ttuegel Can the warning be moved as Ana suggested? |
kore/src/Stats.hs
Outdated
| warnIfLowProductivity = do | ||
| Stats { gc_cpu_ns, cpu_ns } <- liftIO getStats | ||
| when (gc_cpu_ns * 10 > cpu_ns) $ | ||
| logWarning |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any reason we don't want to add a separate entry type, WarnIfLowProductivity, instead of logging this as a LogMessage?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
parsimony :))
I'll add a new entry type 👍
ana-pantilie
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved and added a refactoring commit, please take a look when you have time.
Fixes #1988
Reviewer checklist
stack test --coveragestack haddock