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

feat: add runtime to fxevent.Run events #1240

Merged
merged 1 commit into from
Oct 9, 2024

Conversation

tchung1118
Copy link
Contributor

This PR adds runtime info of constructors and decorators to Run events,
and the runtime of every constructor and decorator (including ones created
by fx.Supply and fx.Replace) will be logged when logging Run events. This
will help us identify which part of the dependency graph takes long to construct.

Closes #1213

Copy link

codecov bot commented Oct 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.42%. Comparing base (99eee83) to head (a8df844).
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1240   +/-   ##
=======================================
  Coverage   98.42%   98.42%           
=======================================
  Files          35       35           
  Lines        2918     2924    +6     
=======================================
+ Hits         2872     2878    +6     
  Misses         38       38           
  Partials        8        8           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@JacobOaks JacobOaks left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@r-hang r-hang left a comment

Choose a reason for hiding this comment

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

lgtm! Nice testing for ns/ms/s

Copy link
Contributor

@sywhang sywhang left a comment

Choose a reason for hiding this comment

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

nice!

@tchung1118 tchung1118 merged commit 57f8ff4 into uber-go:master Oct 9, 2024
12 checks passed
@tchung1118 tchung1118 deleted the taiwon/1213 branch October 9, 2024 19:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Add constructor runtime to fxevent.Run events
4 participants