Skip to content

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

Closed
wants to merge 17 commits into from

Conversation

toddbeckman-wf
Copy link
Contributor

@toddbeckman-wf toddbeckman-wf commented Jul 31, 2018

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.

@aviary2-wf
Copy link

Security Insights

No security relevant content was detected by automated scans.

Action Items

  • Review PR for security impact; comment "security review required" if needed or unsure
  • Verify aviary.yaml coverage of security relevant code

Questions or Comments? Reach out on HipChat: InfoSec Forum.

@@ -0,0 +1,16 @@
class StartupTimingSpecifier {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not my favorite name.

@toddbeckman-wf toddbeckman-wf changed the title Af 1541 additional timing granularity AF-1541 additional timing granularity Jul 31, 2018
@codecov-io
Copy link

codecov-io commented Jul 31, 2018

Codecov Report

Merging #116 into master will decrease coverage by 1.75%.
The diff coverage is 81.66%.

Impacted file tree graph

@@            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
Impacted Files Coverage Δ
lib/src/timing_specifiers.dart 0% <0%> (ø)
lib/src/lifecycle_module.dart 93.53% <83.05%> (-2.41%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e2976ab...1d92e45. Read the comment docs.

_actions.loadData();
return new Future.value();
return null;
Copy link
Contributor

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((_) => ...);

Copy link
Contributor Author

@toddbeckman-wf toddbeckman-wf Jul 31, 2018

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);
Copy link
Contributor

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?

Copy link
Contributor Author

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.

@toddbeckman-wf
Copy link
Contributor Author

Closing for #115

@toddbeckman-wf toddbeckman-wf deleted the AF-1541_additional-timing-granularity branch August 1, 2018 21:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants