https://github.com/si3nloong/log-benchmark
Benchmark for logging and tracing
https://github.com/si3nloong/log-benchmark
benchmark go logging tracing
Last synced: 4 months ago
JSON representation
Benchmark for logging and tracing
- Host: GitHub
- URL: https://github.com/si3nloong/log-benchmark
- Owner: si3nloong
- Created: 2023-01-09T06:10:46.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-03-17T04:06:21.000Z (over 2 years ago)
- Last Synced: 2025-06-08T16:02:51.987Z (4 months ago)
- Topics: benchmark, go, logging, tracing
- Language: Go
- Homepage:
- Size: 164 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Log Benchmarks
> Benchmarks on using logging, tracing and without them.
```bash
# setup jaeger
docker run -d --name jaeger \
-e COLLECTOR_ZIPKIN_HOST_PORT=:9411 \
-e COLLECTOR_OTLP_ENABLED=true \
-p 6831:6831/udp \
-p 6832:6832/udp \
-p 5778:5778 \
-p 16686:16686 \
-p 4317:4317 \
-p 4318:4318 \
-p 14250:14250 \
-p 14268:14268 \
-p 14269:14269 \
-p 9411:9411 \
jaegertracing/all-in-one:1.43
```| Case | Data Size | Total loop | Average elapsed time |
| --------------------------- | :-------: | ---------: | -------------------: |
| Without Logging and Tracing | small | 15217 | 77804 ns/op |
| Without Logging and Tracing | big | 3790 | 267474 ns/op |
| With Tracing | small | 13303 | 90404 ns/op |
| With Tracing | big | 3592 | 308865 ns/op |
| With Logging | small | 5738 | 240336 ns/op |
| With Logging | big | 1150 | 1689071 ns/op |