-
Notifications
You must be signed in to change notification settings - Fork 293
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
instrument Exception and Error classes to avoid instrumenting generic throwables used for control flow #6128
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BenchmarksStartupParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 54 cases. Startup time reports for insecure-bankgantt
title insecure-bank - global startup overhead: candidate=1.23.0-SNAPSHOT~1f99550fee, baseline=1.23.0-SNAPSHOT~0f5ae07427
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.033 s) : 0, 1033212
Total [baseline] (8.806 s) : 0, 8806201
Agent [candidate] (1.035 s) : 0, 1034991
Total [candidate] (8.755 s) : 0, 8754893
section iast
Agent [baseline] (1.152 s) : 0, 1151575
Total [baseline] (9.291 s) : 0, 9290639
Agent [candidate] (1.153 s) : 0, 1153446
Total [candidate] (9.322 s) : 0, 9322032
section iast_TELEMETRY_OFF
Agent [baseline] (1.145 s) : 0, 1145280
Total [baseline] (9.282 s) : 0, 9281825
Agent [candidate] (1.146 s) : 0, 1146077
Total [candidate] (9.308 s) : 0, 9308088
gantt
title insecure-bank - break down per module: candidate=1.23.0-SNAPSHOT~1f99550fee, baseline=1.23.0-SNAPSHOT~0f5ae07427
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (644.665 ms) : 0, 644665
BytebuddyAgent [candidate] (645.816 ms) : 0, 645816
GlobalTracer [baseline] (293.045 ms) : 0, 293045
GlobalTracer [candidate] (293.715 ms) : 0, 293715
AppSec [baseline] (49.163 ms) : 0, 49163
AppSec [candidate] (49.016 ms) : 0, 49016
Remote Config [baseline] (676.03 µs) : 0, 676
Remote Config [candidate] (693.183 µs) : 0, 693
Telemetry [baseline] (11.314 ms) : 0, 11314
Telemetry [candidate] (11.308 ms) : 0, 11308
section iast
BytebuddyAgent [baseline] (763.592 ms) : 0, 763592
BytebuddyAgent [candidate] (766.561 ms) : 0, 766561
GlobalTracer [baseline] (274.741 ms) : 0, 274741
GlobalTracer [candidate] (274.853 ms) : 0, 274853
AppSec [baseline] (46.532 ms) : 0, 46532
AppSec [candidate] (46.772 ms) : 0, 46772
IAST [baseline] (18.493 ms) : 0, 18493
IAST [candidate] (17.669 ms) : 0, 17669
Remote Config [baseline] (556.371 µs) : 0, 556
Remote Config [candidate] (555.601 µs) : 0, 556
Telemetry [baseline] (13.196 ms) : 0, 13196
Telemetry [candidate] (12.475 ms) : 0, 12475
section iast_TELEMETRY_OFF
BytebuddyAgent [baseline] (758.459 ms) : 0, 758459
BytebuddyAgent [candidate] (758.777 ms) : 0, 758777
GlobalTracer [baseline] (274.95 ms) : 0, 274950
GlobalTracer [candidate] (275.245 ms) : 0, 275245
AppSec [baseline] (46.731 ms) : 0, 46731
AppSec [candidate] (46.846 ms) : 0, 46846
IAST [baseline] (18.371 ms) : 0, 18371
IAST [candidate] (18.474 ms) : 0, 18474
Remote Config [baseline] (549.189 µs) : 0, 549
Remote Config [candidate] (566.349 µs) : 0, 566
Telemetry [baseline] (11.828 ms) : 0, 11828
Telemetry [candidate] (11.835 ms) : 0, 11835
Startup time reports for petclinicgantt
title petclinic - global startup overhead: candidate=1.23.0-SNAPSHOT~1f99550fee, baseline=1.23.0-SNAPSHOT~0f5ae07427
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.034 s) : 0, 1034284
Total [baseline] (9.308 s) : 0, 9308320
Agent [candidate] (1.036 s) : 0, 1035857
Total [candidate] (9.332 s) : 0, 9332417
section appsec
Agent [baseline] (1.125 s) : 0, 1124905
Total [baseline] (9.45 s) : 0, 9449769
Agent [candidate] (1.122 s) : 0, 1121602
Total [candidate] (9.418 s) : 0, 9417844
section iast
Agent [baseline] (1.151 s) : 0, 1150558
Total [baseline] (9.57 s) : 0, 9569596
Agent [candidate] (1.166 s) : 0, 1166245
Total [candidate] (9.609 s) : 0, 9608634
section profiling
Agent [baseline] (1.211 s) : 0, 1211126
Total [baseline] (9.582 s) : 0, 9581519
Agent [candidate] (1.217 s) : 0, 1216616
Total [candidate] (9.546 s) : 0, 9545718
gantt
title petclinic - break down per module: candidate=1.23.0-SNAPSHOT~1f99550fee, baseline=1.23.0-SNAPSHOT~0f5ae07427
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (645.206 ms) : 0, 645206
BytebuddyAgent [candidate] (646.153 ms) : 0, 646153
GlobalTracer [baseline] (293.869 ms) : 0, 293869
GlobalTracer [candidate] (294.43 ms) : 0, 294430
AppSec [baseline] (48.909 ms) : 0, 48909
AppSec [candidate] (48.781 ms) : 0, 48781
Remote Config [baseline] (688.182 µs) : 0, 688
Remote Config [candidate] (694.031 µs) : 0, 694
Telemetry [baseline] (11.278 ms) : 0, 11278
Telemetry [candidate] (11.31 ms) : 0, 11310
section appsec
BytebuddyAgent [baseline] (648.486 ms) : 0, 648486
BytebuddyAgent [candidate] (646.788 ms) : 0, 646788
GlobalTracer [baseline] (294.932 ms) : 0, 294932
GlobalTracer [candidate] (294.6 ms) : 0, 294600
AppSec [baseline] (139.524 ms) : 0, 139524
AppSec [candidate] (138.266 ms) : 0, 138266
Remote Config [baseline] (652.934 µs) : 0, 653
Remote Config [candidate] (641.511 µs) : 0, 642
Telemetry [baseline] (6.92 ms) : 0, 6920
Telemetry [candidate] (6.888 ms) : 0, 6888
section iast
BytebuddyAgent [baseline] (763.96 ms) : 0, 763960
BytebuddyAgent [candidate] (777.833 ms) : 0, 777833
GlobalTracer [baseline] (274.931 ms) : 0, 274931
GlobalTracer [candidate] (278.117 ms) : 0, 278117
AppSec [baseline] (46.383 ms) : 0, 46383
AppSec [candidate] (47.554 ms) : 0, 47554
IAST [baseline] (17.788 ms) : 0, 17788
IAST [candidate] (15.829 ms) : 0, 15829
Remote Config [baseline] (549.622 µs) : 0, 550
Remote Config [candidate] (553.596 µs) : 0, 554
Telemetry [baseline] (12.505 ms) : 0, 12505
Telemetry [candidate] (11.406 ms) : 0, 11406
section profiling
BytebuddyAgent [baseline] (655.027 ms) : 0, 655027
BytebuddyAgent [candidate] (660.679 ms) : 0, 660679
GlobalTracer [baseline] (359.185 ms) : 0, 359185
GlobalTracer [candidate] (358.956 ms) : 0, 358956
AppSec [baseline] (49.655 ms) : 0, 49655
AppSec [candidate] (49.358 ms) : 0, 49358
Remote Config [baseline] (642.422 µs) : 0, 642
Remote Config [candidate] (638.798 µs) : 0, 639
Telemetry [baseline] (11.319 ms) : 0, 11319
Telemetry [candidate] (11.33 ms) : 0, 11330
ProfilingAgent [baseline] (80.971 ms) : 0, 80971
ProfilingAgent [candidate] (80.81 ms) : 0, 80810
Profiling [baseline] (80.995 ms) : 0, 80995
Profiling [candidate] (80.835 ms) : 0, 80835
LoadParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 22 cases. Request duration reports for insecure-bankgantt
title insecure-bank - request duration [CI 0.99] : candidate=1.23.0-SNAPSHOT~1f99550fee, baseline=1.23.0-SNAPSHOT~0f5ae07427
dateFormat X
axisFormat %s
section baseline
no_agent (363.587 µs) : 343, 384
. : milestone, 364,
iast (460.009 µs) : 439, 481
. : milestone, 460,
iast_FULL (524.628 µs) : 504, 545
. : milestone, 525,
iast_INACTIVE (438.482 µs) : 418, 459
. : milestone, 438,
iast_TELEMETRY_OFF (466.699 µs) : 446, 488
. : milestone, 467,
tracing (434.195 µs) : 412, 456
. : milestone, 434,
section candidate
no_agent (362.012 µs) : 342, 382
. : milestone, 362,
iast (464.798 µs) : 444, 486
. : milestone, 465,
iast_FULL (530.559 µs) : 510, 551
. : milestone, 531,
iast_INACTIVE (432.524 µs) : 411, 454
. : milestone, 433,
iast_TELEMETRY_OFF (461.705 µs) : 441, 483
. : milestone, 462,
tracing (429.09 µs) : 408, 450
. : milestone, 429,
Request duration reports for petclinicgantt
title petclinic - request duration [CI 0.99] : candidate=1.23.0-SNAPSHOT~1f99550fee, baseline=1.23.0-SNAPSHOT~0f5ae07427
dateFormat X
axisFormat %s
section baseline
no_agent (1.351 ms) : 1332, 1371
. : milestone, 1351,
appsec (1.739 ms) : 1715, 1764
. : milestone, 1739,
iast (1.483 ms) : 1459, 1507
. : milestone, 1483,
profiling (1.487 ms) : 1462, 1512
. : milestone, 1487,
tracing (1.474 ms) : 1449, 1499
. : milestone, 1474,
section candidate
no_agent (1.349 ms) : 1330, 1368
. : milestone, 1349,
appsec (1.718 ms) : 1693, 1742
. : milestone, 1718,
iast (1.506 ms) : 1482, 1530
. : milestone, 1506,
profiling (1.481 ms) : 1454, 1507
. : milestone, 1481,
tracing (1.479 ms) : 1455, 1503
. : milestone, 1479,
|
richardstartin
force-pushed
the
rgs/refactor-exception-profiling
branch
2 times, most recently
from
November 1, 2023 13:48
735ada3
to
06b6a79
Compare
richardstartin
changed the title
instrument exception and error to avoid instrumenting generic throwables used for control flow
instrument Exception and Error classes to avoid instrumenting generic throwables used for control flow
Nov 1, 2023
…les used for control flow
richardstartin
force-pushed
the
rgs/refactor-exception-profiling
branch
from
November 1, 2023 15:42
06b6a79
to
1f99550
Compare
richardstartin
requested review from
ygree,
nayeem-kamal,
jbachorik and
bantonsson
November 1, 2023 15:49
jbachorik
approved these changes
Nov 1, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What Does This Do
This instruments the
Exception
andError
classes in thejava.lang
andkotlin
packages, instead ofThrowable
which avoids several throwable types used for control flow, such as Scala'sControlThrowable
. This also avoids resource tracking mechanisms such as Netty'sResourceLeakDetector
which we were filtering out.Avoiding the instrumentation altogether in these non-exceptional cases is important because the instrumentation interferes with escape analysis and ensuing optimisations which can reduce the cost of these exception types to practically nothing.
Motivation
Additional Notes
Jira ticket: PROF-8556