-
Notifications
You must be signed in to change notification settings - Fork 16
AF-1541 additional timing granularity #116
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
Conversation
Security InsightsNo security relevant content was detected by automated scans. Action Items
Questions or Comments? Reach out on HipChat: InfoSec Forum. |
@@ -0,0 +1,16 @@ | |||
class StartupTimingSpecifier { |
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.
Not my favorite name.
Codecov Report
@@ Coverage Diff @@
## master #116 +/- ##
==========================================
- Coverage 93.49% 91.74% -1.76%
==========================================
Files 4 5 +1
Lines 369 424 +55
==========================================
+ Hits 345 389 +44
- Misses 24 35 +11
Continue to review full report at Codecov.
|
_actions.loadData(); | ||
return new Future.value(); | ||
return null; |
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.
This could introduce an issue if a consumer treats the returned Future
directly.
// This will throw.
_module.onLoad().then((_) => ...);
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.
I was just toying around with the examples and forgot to put it back. I'll probably do that before pushing for the reviews on this.
void addTags(Map<String, dynamic> newTags) => tags.addAll(newTags); | ||
|
||
@override | ||
Duration get duration => _endTime?.difference(startTime); |
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.
❓Are consumers of Span
aware that this may be null?
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.
I figure it's not important here because it's just in the examples.
…r-specified-timing
…r-specified-timing
…nal-timing-granularity
Closing for #115 |
Note
Merges #115. Clean diff: AF-1540_consumer-specified-timing...AF-1541_additional-timing-granularity
It will result in a breaking API change if they are merged separately. Handle this before merging either this or that, or merge together.
Description
There are other useful startup time properties that would be nice to measure. Allow consumers to call a method with a specifier for which timing operation this is.
Testing
See the
DataLoadAsync
example.