1
0
mirror of https://github.com/open-telemetry/opentelemetry-go.git synced 2024-12-28 21:09:17 +02:00
opentelemetry-go/sdk/trace
Damien Mathieu 4987a1dd4b
Split the span start/end benchmarks and test start with links and attributes (#5554)
I was looking at the trace benchmarks, and noticed this one, which says
it tests "span start", but ending the span is included within the data.
So this change removes ending the span from the computation, and adds a
new benchmark which only computes span end.

benchstat for span start:

```
pkg: go.opentelemetry.io/otel/sdk/trace
              │ bench-main  │            bench-branch            │
              │   sec/op    │   sec/op     vs base               │
TraceStart-10   725.6n ± 3%   667.2n ± 2%  -8.04% (p=0.000 n=10)

              │ bench-main │          bench-branch          │
              │    B/op    │    B/op     vs base            │
TraceStart-10   704.0 ± 0%   704.0 ± 0%  ~ (p=1.000 n=10) ¹
¹ all samples are equal

              │ bench-main │          bench-branch          │
              │ allocs/op  │ allocs/op   vs base            │
TraceStart-10   14.00 ± 0%   14.00 ± 0%  ~ (p=1.000 n=10) ¹
¹ all samples are equal
```

Benchmark for span end:
```
BenchmarkSpanEnd-10     16486819               147.7 ns/op             0 B/op          0 allocs/op
```
2024-06-28 11:51:09 +02:00
..
tracetest Add READMEs to every package (#5103) 2024-03-26 20:13:54 +01:00
batch_span_processor_test.go Add errorlint linter (#5535) 2024-06-25 10:55:00 -07:00
batch_span_processor.go Add unparam linter (#5531) 2024-06-21 16:02:07 -07:00
benchmark_test.go Add unparam linter (#5531) 2024-06-21 16:02:07 -07:00
doc.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
event.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
evictedqueue_test.go trace: Use non-generic to replace newEvictedQueue in trace.start to reduce memory usage. (#5497) 2024-06-17 07:39:03 -07:00
evictedqueue.go trace: Use non-generic to replace newEvictedQueue in trace.start to reduce memory usage. (#5497) 2024-06-17 07:39:03 -07:00
id_generator_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
id_generator.go Fix IDGenerator may generate zero TraceId / SpanId (#5514) 2024-06-18 15:57:45 -07:00
link.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
provider_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
provider.go Add errorlint linter (#5535) 2024-06-25 10:55:00 -07:00
README.md Add READMEs to every package (#5103) 2024-03-26 20:13:54 +01:00
sampler_env.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
sampling_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
sampling.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
simple_span_processor_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
simple_span_processor.go sdk/trace: fix spelling errors (#4996) 2024-03-25 13:10:08 +01:00
snapshot.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_exporter.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_limits_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_limits.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_processor_annotator_example_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_processor_filter_example_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_processor_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_processor.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
span_test.go Split the span start/end benchmarks and test start with links and attributes (#5554) 2024-06-28 11:51:09 +02:00
span.go Upgrade semconv use to v1.26.0 (#5490) 2024-06-06 09:36:59 -07:00
trace_test.go Split the span start/end benchmarks and test start with links and attributes (#5554) 2024-06-28 11:51:09 +02:00
tracer.go trace: Use non-generic to replace newEvictedQueue in trace.start to reduce memory usage. (#5497) 2024-06-17 07:39:03 -07:00
util_test.go Add unparam linter (#5531) 2024-06-21 16:02:07 -07:00
version_test.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00
version.go [chore] Simplify the license header (#4987) 2024-02-29 07:05:28 +01:00

SDK Trace

PkgGoDev