Skip to content

Small cleanup on MeterProvider#2172

Merged
cijothomas merged 1 commit intometricsfrom
cijothomas/metricprovidercleanups2
Jul 21, 2021
Merged

Small cleanup on MeterProvider#2172
cijothomas merged 1 commit intometricsfrom
cijothomas/metricprovidercleanups2

Conversation

@cijothomas
Copy link
Member

Provider doesn't have any tasks, so its dispose simply calls dispose on the processors (which may have tasks to be disposed)

@cijothomas cijothomas requested a review from a team July 21, 2021 17:47
@codecov
Copy link

codecov bot commented Jul 21, 2021

Codecov Report

Merging #2172 (be0a1be) into metrics (94c6e56) will increase coverage by 0.01%.
The diff coverage is 0.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           metrics    #2172      +/-   ##
===========================================
+ Coverage    74.58%   74.60%   +0.01%     
===========================================
  Files          218      218              
  Lines         6957     6957              
===========================================
+ Hits          5189     5190       +1     
+ Misses        1768     1767       -1     
Impacted Files Coverage Δ
src/OpenTelemetry/Metrics/MeterProviderSdk.cs 0.00% <0.00%> (ø)
...elemetry/Metrics/Processors/PushMetricProcessor.cs 0.00% <0.00%> (ø)
...emetry.Api/Internal/OpenTelemetryApiEventSource.cs 82.35% <0.00%> (+2.94%) ⬆️

{
this.token.Cancel();
this.exporter.Dispose();
this.exportTask.Wait();
Copy link
Member

Choose a reason for hiding this comment

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

Btw, do we see the real difference between push/pull metric processors? I personally don't (and I'm thinking maybe we should remove push/pull concept from the draft spec).

Copy link
Member Author

Choose a reason for hiding this comment

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

Not much, since the MeterProvider provided a way to "Collect". PushProcessor calls this Collect every N seconds. PullProcessor calls this Collect whenever its asked to.

@cijothomas cijothomas merged commit 49f3c18 into metrics Jul 21, 2021
@cijothomas cijothomas deleted the cijothomas/metricprovidercleanups2 branch July 21, 2021 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants