-
Notifications
You must be signed in to change notification settings - Fork 659
[heft] feat: add new task-level timing metrics #5232
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
[heft] feat: add new task-level timing metrics #5232
Conversation
| { | ||
| "$schema": "http://json.schemastore.org/tsconfig", | ||
|
|
||
| "compilerOptions": { |
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.
Pretty sure we have a rig we should be extending for this?
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.
@dmichon-msft Looking through a few other heft example plugins, I don't see anything - do you know which one that would be?
|
Realizing that I also want a edit: I think what I'd be looking for would be start + end hooks for heft phases, which I don't love adding as public API rn. Task-level metrics are a good start :) |
28a094e to
3dac4c8
Compare
Signed-off-by: Aramis Sennyey <[email protected]>
3dac4c8 to
9b9fe3b
Compare
|
@dmichon-msft What do you think about instead implementing this as |
|
closing in favor of #5250 |
Summary
Adds task-level metrics for reporting on how long specific plugins take to execute, like the Typescript, Jest, and Webpack plugins. These are currently only logged out to console in verbose mode.
Details
I copied most of the existing implementation of the
recordMetricshook to create arecordTaskMetricshook - the idea here is being able to report on the specific amount of time that each task takes and add more granular reporting. Let me know what you think about the metric envelope.How it was tested
Added a test
heft-lifecycle-pluginthat logs out the time taken for each task (you can still see the verbose logs too). Example:Impacted documentation
Not sure?