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

fix: prevent duplicated resource creation #1015

Merged
merged 1 commit into from
May 6, 2020

Conversation

legendecas
Copy link
Member

Which problem is this PR solving?

Short description of the changes

  • Prevent default resource re-creation in Meter/Tracer by propagating default resource in MeterProvider/TracerProvider.

@codecov-io
Copy link

codecov-io commented May 4, 2020

Codecov Report

Merging #1015 into master will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #1015   +/-   ##
=======================================
  Coverage   95.00%   95.01%           
=======================================
  Files         212      212           
  Lines        8813     8827   +14     
  Branches      796      797    +1     
=======================================
+ Hits         8373     8387   +14     
  Misses        440      440           
Impacted Files Coverage Δ
...ackages/opentelemetry-metrics/src/MeterProvider.ts 100.00% <100.00%> (ø)
...s/opentelemetry-metrics/test/MeterProvider.test.ts 100.00% <100.00%> (ø)
...s/opentelemetry-tracing/src/BasicTracerProvider.ts 75.75% <100.00%> (+0.75%) ⬆️
...telemetry-tracing/test/BasicTracerProvider.test.ts 100.00% <100.00%> (ø)

@dyladan
Copy link
Member

dyladan commented May 4, 2020

We might be better off only saving the properties we need (like logger and resource) and not saving a _config property at all. It is unnecessary duplication.

@mayurkale22 mayurkale22 added enhancement New feature or request size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels May 4, 2020
Copy link
Member

@mayurkale22 mayurkale22 left a comment

Choose a reason for hiding this comment

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

LGTM

@mayurkale22 mayurkale22 merged commit e2205ef into open-telemetry:master May 6, 2020
@legendecas legendecas deleted the resource branch May 6, 2020 03:22
pichlermarc pushed a commit to dynatrace-oss-contrib/opentelemetry-js that referenced this pull request Dec 15, 2023
…en-telemetry#1015)

* fix(sns-publish-test-v3): add test for sns.publish for aws sdk v3

* fix(add-header-to-payloads): fix lint errors

* fix(sns-publish-test-v3): fix lint problems

* fix(sns-publish-test-v3): fix lint problems

* fix(sns-publish-test-v3): fix sns version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants