Skip to content

Commit

Permalink
Fix class member initialization order (#1360)
Browse files Browse the repository at this point in the history
  • Loading branch information
lalitb authored Apr 30, 2022
1 parent f314522 commit 8ef6764
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -761,10 +761,10 @@ class Span : public opentelemetry::trace::Span
const opentelemetry::trace::StartSpanOptions &options,
Span *parent = nullptr) noexcept
: opentelemetry::trace::Span(),
start_time_(std::chrono::system_clock::now()),
owner_(owner),
parent_(parent),
context_(CreateContext()),
start_time_(std::chrono::system_clock::now())
context_(CreateContext())
{
name_ = name;
UNREFERENCED_PARAMETER(options);
Expand Down
2 changes: 1 addition & 1 deletion sdk/src/metrics/meter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ namespace nostd = opentelemetry::nostd;
Meter::Meter(std::shared_ptr<MeterContext> meter_context,
std::unique_ptr<sdk::instrumentationlibrary::InstrumentationLibrary>
instrumentation_library) noexcept
: meter_context_{meter_context}, instrumentation_library_{std::move(instrumentation_library)}
: instrumentation_library_{std::move(instrumentation_library)}, meter_context_{meter_context}
{}

nostd::shared_ptr<metrics::Counter<long>> Meter::CreateLongCounter(nostd::string_view name,
Expand Down

1 comment on commit 8ef6764

@github-actions
Copy link

Choose a reason for hiding this comment

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

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'OpenTelemetry-cpp api Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 2.

Benchmark suite Current: 8ef6764 Previous: f314522 Ratio
BM_SpinLockThrashing/1/process_time/real_time 0.3023415857997001 ms/iter 0.13015860899042342 ms/iter 2.32
BM_ThreadYieldSpinLockThrashing/1/process_time/real_time 14.92192870692203 ms/iter 6.925225257873535 ms/iter 2.15
BM_ThreadYieldSpinLockThrashing/2/process_time/real_time 71.76244258880615 ms/iter 28.99637222290039 ms/iter 2.47

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.