-
Notifications
You must be signed in to change notification settings - Fork 318
Add metrics OpenTelemetry instrumentation entry mechanism #9908
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
base: master
Are you sure you want to change the base?
Conversation
This comment has been minimized.
This comment has been minimized.
BenchmarksStartupParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 59 metrics, 6 unstable metrics. Startup time reports for petclinicgantt
title petclinic - global startup overhead: candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.1 s) : 0, 1099636
Total [baseline] (10.817 s) : 0, 10817279
Agent [candidate] (1.103 s) : 0, 1102705
Total [candidate] (10.859 s) : 0, 10859365
section appsec
Agent [baseline] (1.282 s) : 0, 1282136
Total [baseline] (11.146 s) : 0, 11146216
Agent [candidate] (1.287 s) : 0, 1286832
Total [candidate] (11.133 s) : 0, 11132706
section iast
Agent [baseline] (1.24 s) : 0, 1239763
Total [baseline] (11.271 s) : 0, 11270829
Agent [candidate] (1.24 s) : 0, 1239578
Total [candidate] (11.262 s) : 0, 11261754
section profiling
Agent [baseline] (1.231 s) : 0, 1231088
Total [baseline] (11.125 s) : 0, 11125070
Agent [candidate] (1.234 s) : 0, 1233895
Total [candidate] (11.142 s) : 0, 11142131
gantt
title petclinic - break down per module: candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.481 ms) : 0, 1481
crashtracking [candidate] (1.476 ms) : 0, 1476
BytebuddyAgent [baseline] (706.333 ms) : 0, 706333
BytebuddyAgent [candidate] (708.41 ms) : 0, 708410
GlobalTracer [baseline] (248.529 ms) : 0, 248529
GlobalTracer [candidate] (249.546 ms) : 0, 249546
AppSec [baseline] (31.955 ms) : 0, 31955
AppSec [candidate] (31.849 ms) : 0, 31849
Debugger [baseline] (64.043 ms) : 0, 64043
Debugger [candidate] (64.007 ms) : 0, 64007
Remote Config [baseline] (631.568 µs) : 0, 632
Remote Config [candidate] (622.988 µs) : 0, 623
Telemetry [baseline] (8.275 ms) : 0, 8275
Telemetry [candidate] (8.268 ms) : 0, 8268
Flare Poller [baseline] (3.68 ms) : 0, 3680
Flare Poller [candidate] (3.688 ms) : 0, 3688
section appsec
crashtracking [baseline] (1.477 ms) : 0, 1477
crashtracking [candidate] (1.484 ms) : 0, 1484
BytebuddyAgent [baseline] (731.856 ms) : 0, 731856
BytebuddyAgent [candidate] (735.111 ms) : 0, 735111
GlobalTracer [baseline] (240.488 ms) : 0, 240488
GlobalTracer [candidate] (241.9 ms) : 0, 241900
IAST [baseline] (24.812 ms) : 0, 24812
IAST [candidate] (24.829 ms) : 0, 24829
AppSec [baseline] (174.515 ms) : 0, 174515
AppSec [candidate] (174.235 ms) : 0, 174235
Debugger [baseline] (61.257 ms) : 0, 61257
Debugger [candidate] (61.487 ms) : 0, 61487
Remote Config [baseline] (674.586 µs) : 0, 675
Remote Config [candidate] (675.046 µs) : 0, 675
Telemetry [baseline] (8.198 ms) : 0, 8198
Telemetry [candidate] (8.102 ms) : 0, 8102
Flare Poller [baseline] (3.925 ms) : 0, 3925
Flare Poller [candidate] (4.024 ms) : 0, 4024
section iast
crashtracking [baseline] (1.493 ms) : 0, 1493
crashtracking [candidate] (1.476 ms) : 0, 1476
BytebuddyAgent [baseline] (831.81 ms) : 0, 831810
BytebuddyAgent [candidate] (832.636 ms) : 0, 832636
GlobalTracer [baseline] (238.058 ms) : 0, 238058
GlobalTracer [candidate] (237.036 ms) : 0, 237036
IAST [baseline] (28.365 ms) : 0, 28365
IAST [candidate] (29.215 ms) : 0, 29215
AppSec [baseline] (33.026 ms) : 0, 33026
AppSec [candidate] (32.133 ms) : 0, 32133
Debugger [baseline] (60.62 ms) : 0, 60620
Debugger [candidate] (60.558 ms) : 0, 60558
Remote Config [baseline] (538.57 µs) : 0, 539
Remote Config [candidate] (541.401 µs) : 0, 541
Telemetry [baseline] (7.575 ms) : 0, 7575
Telemetry [candidate] (7.585 ms) : 0, 7585
Flare Poller [baseline] (3.467 ms) : 0, 3467
Flare Poller [candidate] (3.554 ms) : 0, 3554
section profiling
crashtracking [baseline] (1.437 ms) : 0, 1437
crashtracking [candidate] (1.436 ms) : 0, 1436
BytebuddyAgent [baseline] (733.118 ms) : 0, 733118
BytebuddyAgent [candidate] (734.344 ms) : 0, 734344
GlobalTracer [baseline] (222.833 ms) : 0, 222833
GlobalTracer [candidate] (222.53 ms) : 0, 222530
AppSec [baseline] (32.052 ms) : 0, 32052
AppSec [candidate] (32.333 ms) : 0, 32333
Debugger [baseline] (63.437 ms) : 0, 63437
Debugger [candidate] (64.264 ms) : 0, 64264
Remote Config [baseline] (656.902 µs) : 0, 657
Remote Config [candidate] (662.12 µs) : 0, 662
Telemetry [baseline] (7.904 ms) : 0, 7904
Telemetry [candidate] (8.162 ms) : 0, 8162
Flare Poller [baseline] (3.749 ms) : 0, 3749
Flare Poller [candidate] (3.803 ms) : 0, 3803
ProfilingAgent [baseline] (96.789 ms) : 0, 96789
ProfilingAgent [candidate] (97.251 ms) : 0, 97251
Profiling [baseline] (97.375 ms) : 0, 97375
Profiling [candidate] (97.83 ms) : 0, 97830
Startup time reports for insecure-bankgantt
title insecure-bank - global startup overhead: candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.103 s) : 0, 1102619
Total [baseline] (8.829 s) : 0, 8828795
Agent [candidate] (1.103 s) : 0, 1102991
Total [candidate] (8.913 s) : 0, 8912702
section iast
Agent [baseline] (1.239 s) : 0, 1239221
Total [baseline] (9.58 s) : 0, 9579631
Agent [candidate] (1.24 s) : 0, 1239723
Total [candidate] (9.583 s) : 0, 9582716
gantt
title insecure-bank - break down per module: candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.494 ms) : 0, 1494
crashtracking [candidate] (1.479 ms) : 0, 1479
BytebuddyAgent [baseline] (709.209 ms) : 0, 709209
BytebuddyAgent [candidate] (708.657 ms) : 0, 708657
GlobalTracer [baseline] (249.321 ms) : 0, 249321
GlobalTracer [candidate] (249.589 ms) : 0, 249589
AppSec [baseline] (32.023 ms) : 0, 32023
AppSec [candidate] (32.0 ms) : 0, 32000
Debugger [baseline] (63.209 ms) : 0, 63209
Debugger [candidate] (63.829 ms) : 0, 63829
Remote Config [baseline] (631.155 µs) : 0, 631
Remote Config [candidate] (629.297 µs) : 0, 629
Telemetry [baseline] (8.117 ms) : 0, 8117
Telemetry [candidate] (8.173 ms) : 0, 8173
Flare Poller [baseline] (3.634 ms) : 0, 3634
Flare Poller [candidate] (3.708 ms) : 0, 3708
section iast
crashtracking [baseline] (1.495 ms) : 0, 1495
crashtracking [candidate] (1.493 ms) : 0, 1493
BytebuddyAgent [baseline] (832.095 ms) : 0, 832095
BytebuddyAgent [candidate] (832.655 ms) : 0, 832655
GlobalTracer [baseline] (237.582 ms) : 0, 237582
GlobalTracer [candidate] (237.408 ms) : 0, 237408
AppSec [baseline] (32.435 ms) : 0, 32435
AppSec [candidate] (30.56 ms) : 0, 30560
Debugger [baseline] (59.999 ms) : 0, 59999
Debugger [candidate] (59.887 ms) : 0, 59887
Remote Config [baseline] (558.078 µs) : 0, 558
Remote Config [candidate] (558.974 µs) : 0, 559
Telemetry [baseline] (7.632 ms) : 0, 7632
Telemetry [candidate] (7.632 ms) : 0, 7632
Flare Poller [baseline] (3.487 ms) : 0, 3487
Flare Poller [candidate] (3.582 ms) : 0, 3582
IAST [baseline] (29.1 ms) : 0, 29100
IAST [candidate] (31.145 ms) : 0, 31145
LoadParameters
See matching parameters
SummaryFound 0 performance improvements and 1 performance regressions! Performance is the same for 20 metrics, 15 unstable metrics.
Request duration reports for insecure-bankgantt
title insecure-bank - request duration [CI 0.99] : candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section baseline
no_agent (1.206 ms) : 1194, 1218
. : milestone, 1206,
iast (3.25 ms) : 3200, 3300
. : milestone, 3250,
iast_FULL (5.765 ms) : 5707, 5823
. : milestone, 5765,
iast_GLOBAL (3.606 ms) : 3553, 3659
. : milestone, 3606,
profiling (1.957 ms) : 1940, 1974
. : milestone, 1957,
tracing (1.812 ms) : 1798, 1827
. : milestone, 1812,
section candidate
no_agent (1.201 ms) : 1189, 1213
. : milestone, 1201,
iast (3.288 ms) : 3241, 3335
. : milestone, 3288,
iast_FULL (5.773 ms) : 5715, 5831
. : milestone, 5773,
iast_GLOBAL (3.637 ms) : 3566, 3708
. : milestone, 3637,
profiling (2.158 ms) : 2138, 2178
. : milestone, 2158,
tracing (1.81 ms) : 1795, 1825
. : milestone, 1810,
Request duration reports for petclinicgantt
title petclinic - request duration [CI 0.99] : candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section baseline
no_agent (18.768 ms) : 18581, 18956
. : milestone, 18768,
appsec (18.523 ms) : 18337, 18710
. : milestone, 18523,
code_origins (17.654 ms) : 17479, 17829
. : milestone, 17654,
iast (17.82 ms) : 17644, 17996
. : milestone, 17820,
profiling (19.444 ms) : 19249, 19639
. : milestone, 19444,
tracing (17.772 ms) : 17593, 17951
. : milestone, 17772,
section candidate
no_agent (18.78 ms) : 18592, 18969
. : milestone, 18780,
appsec (18.689 ms) : 18500, 18878
. : milestone, 18689,
code_origins (17.69 ms) : 17516, 17863
. : milestone, 17690,
iast (17.549 ms) : 17374, 17723
. : milestone, 17549,
profiling (19.079 ms) : 18888, 19271
. : milestone, 19079,
tracing (17.717 ms) : 17541, 17893
. : milestone, 17717,
DacapoParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 12 metrics, 0 unstable metrics. Execution time for tomcatgantt
title tomcat - execution time [CI 0.99] : candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section baseline
no_agent (1.478 ms) : 1467, 1490
. : milestone, 1478,
appsec (2.475 ms) : 2424, 2527
. : milestone, 2475,
iast (2.23 ms) : 2165, 2295
. : milestone, 2230,
iast_GLOBAL (2.27 ms) : 2205, 2335
. : milestone, 2270,
profiling (2.087 ms) : 2035, 2140
. : milestone, 2087,
tracing (2.061 ms) : 2010, 2112
. : milestone, 2061,
section candidate
no_agent (1.48 ms) : 1468, 1491
. : milestone, 1480,
appsec (2.481 ms) : 2428, 2533
. : milestone, 2481,
iast (2.229 ms) : 2164, 2294
. : milestone, 2229,
iast_GLOBAL (2.265 ms) : 2199, 2330
. : milestone, 2265,
profiling (2.083 ms) : 2030, 2136
. : milestone, 2083,
tracing (2.057 ms) : 2005, 2108
. : milestone, 2057,
Execution time for biojavagantt
title biojava - execution time [CI 0.99] : candidate=1.55.0-SNAPSHOT~b4d62f343d, baseline=1.57.0-SNAPSHOT~c8bb44440b
dateFormat X
axisFormat %s
section baseline
no_agent (15.481 s) : 15481000, 15481000
. : milestone, 15481000,
appsec (14.861 s) : 14861000, 14861000
. : milestone, 14861000,
iast (18.102 s) : 18102000, 18102000
. : milestone, 18102000,
iast_GLOBAL (17.867 s) : 17867000, 17867000
. : milestone, 17867000,
profiling (14.604 s) : 14604000, 14604000
. : milestone, 14604000,
tracing (14.828 s) : 14828000, 14828000
. : milestone, 14828000,
section candidate
no_agent (15.668 s) : 15668000, 15668000
. : milestone, 15668000,
appsec (14.745 s) : 14745000, 14745000
. : milestone, 14745000,
iast (18.588 s) : 18588000, 18588000
. : milestone, 18588000,
iast_GLOBAL (18.052 s) : 18052000, 18052000
. : milestone, 18052000,
profiling (15.237 s) : 15237000, 15237000
. : milestone, 15237000,
tracing (15.0 s) : 15000000, 15000000
. : milestone, 15000000,
|
| private final Map<String, List<Meter>> meters; | ||
|
|
||
| public OtelMeterProvider() { | ||
| this.meters = new HashMap<>(); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| private final Map<String, List<Meter>> meters; | |
| public OtelMeterProvider() { | |
| this.meters = new HashMap<>(); | |
| } | |
| private final Map<String, List<Meter>> scopedMeters = new ConcurrentHashMap(); |
Users may call this from different threads, so the map needs to handle concurrent updates.
Also final fields can be assigned in the same line, avoiding the need to do that in the constructor.
This can mean you can drop the constructor completely, making the code more concise.
Lastly I would call this field scopedMeters because it holds meters indexed by scope.
(This helps make the code clearer later on when you query scopedMeters and store the list of meters for that scope in a variable called meters)
What Does This Do
Initial OpenTelemetry metrics instrumentation and stubbed types to support the OTel metrics API - tests will be added as the various stubs are replaced with real implementations
Motivation
OpenTelemetry Metrics API support
Additional Notes
Jira ticket: APMAPI-1671