Add PROVIDER_FATAL state propagation for non-retryable RC errors#11195
Draft
Add PROVIDER_FATAL state propagation for non-retryable RC errors#11195
Conversation
When the RC endpoint returns a non-retryable 4xx (401, 403), the OpenFeature provider now transitions to PROVIDER_FATAL instead of blocking indefinitely or timing out with PROVIDER_NOT_READY. Code path: - DefaultConfigurationPoller.sendRequest() detects 401/403 and notifies registered NonRetryableErrorListeners - RemoteConfigServiceImpl registers such a listener and forwards to FeatureFlaggingGateway.dispatchFatalError() - DDEvaluator implements FeatureFlaggingGateway.FatalErrorListener; on receipt it stores the error message and releases the initialization latch - DDEvaluator.initialize() throws FatalError after the latch is released with a fatal error present - Provider.initialize() re-throws FatalError (it extends OpenFeatureError) causing the OpenFeature SDK to set state to PROVIDER_FATAL
BenchmarksStartupParameters
See matching parameters
SummaryFound 0 performance improvements and 5 performance regressions! Performance is the same for 55 metrics, 11 unstable metrics.
Startup time reports for insecure-bankgantt
title insecure-bank - global startup overhead: candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.057 s) : 0, 1056809
Total [baseline] (8.829 s) : 0, 8829210
Agent [candidate] (1.057 s) : 0, 1057114
Total [candidate] (8.815 s) : 0, 8815367
section iast
Agent [baseline] (1.24 s) : 0, 1239725
Total [baseline] (9.535 s) : 0, 9534831
Agent [candidate] (1.242 s) : 0, 1241953
Total [candidate] (9.561 s) : 0, 9560914
gantt
title insecure-bank - break down per module: candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.226 ms) : 0, 1226
crashtracking [candidate] (1.219 ms) : 0, 1219
BytebuddyAgent [baseline] (635.843 ms) : 0, 635843
BytebuddyAgent [candidate] (635.835 ms) : 0, 635835
AgentMeter [baseline] (29.486 ms) : 0, 29486
AgentMeter [candidate] (29.468 ms) : 0, 29468
GlobalTracer [baseline] (248.879 ms) : 0, 248879
GlobalTracer [candidate] (248.918 ms) : 0, 248918
AppSec [baseline] (32.564 ms) : 0, 32564
AppSec [candidate] (32.225 ms) : 0, 32225
Debugger [baseline] (59.733 ms) : 0, 59733
Debugger [candidate] (59.542 ms) : 0, 59542
Remote Config [baseline] (597.972 µs) : 0, 598
Remote Config [candidate] (740.889 µs) : 0, 741
Telemetry [baseline] (7.989 ms) : 0, 7989
Telemetry [candidate] (7.99 ms) : 0, 7990
Flare Poller [baseline] (4.297 ms) : 0, 4297
Flare Poller [candidate] (5.077 ms) : 0, 5077
section iast
crashtracking [baseline] (1.23 ms) : 0, 1230
crashtracking [candidate] (1.245 ms) : 0, 1245
BytebuddyAgent [baseline] (813.794 ms) : 0, 813794
BytebuddyAgent [candidate] (815.401 ms) : 0, 815401
AgentMeter [baseline] (11.463 ms) : 0, 11463
AgentMeter [candidate] (11.439 ms) : 0, 11439
GlobalTracer [baseline] (241.965 ms) : 0, 241965
GlobalTracer [candidate] (241.451 ms) : 0, 241451
IAST [baseline] (32.146 ms) : 0, 32146
IAST [candidate] (28.65 ms) : 0, 28650
AppSec [baseline] (27.734 ms) : 0, 27734
AppSec [candidate] (30.774 ms) : 0, 30774
Debugger [baseline] (63.536 ms) : 0, 63536
Debugger [candidate] (64.562 ms) : 0, 64562
Remote Config [baseline] (533.94 µs) : 0, 534
Remote Config [candidate] (675.266 µs) : 0, 675
Telemetry [baseline] (7.753 ms) : 0, 7753
Telemetry [candidate] (7.973 ms) : 0, 7973
Flare Poller [baseline] (3.455 ms) : 0, 3455
Flare Poller [candidate] (3.58 ms) : 0, 3580
Startup time reports for petclinicgantt
title petclinic - global startup overhead: candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.059 s) : 0, 1059140
Total [baseline] (11.06 s) : 0, 11060208
Agent [candidate] (1.073 s) : 0, 1072661
Total [candidate] (11.068 s) : 0, 11068443
section appsec
Agent [baseline] (1.277 s) : 0, 1276752
Total [baseline] (11.089 s) : 0, 11089271
Agent [candidate] (1.267 s) : 0, 1266774
Total [candidate] (10.986 s) : 0, 10985503
section iast
Agent [baseline] (1.234 s) : 0, 1233939
Total [baseline] (11.346 s) : 0, 11346279
Agent [candidate] (1.243 s) : 0, 1242718
Total [candidate] (11.177 s) : 0, 11176744
section profiling
Agent [baseline] (1.193 s) : 0, 1192743
Total [baseline] (11.073 s) : 0, 11073078
Agent [candidate] (1.184 s) : 0, 1184386
Total [candidate] (11.167 s) : 0, 11166527
gantt
title petclinic - break down per module: candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.238 ms) : 0, 1238
crashtracking [candidate] (1.254 ms) : 0, 1254
BytebuddyAgent [baseline] (636.339 ms) : 0, 636339
BytebuddyAgent [candidate] (644.41 ms) : 0, 644410
AgentMeter [baseline] (29.413 ms) : 0, 29413
AgentMeter [candidate] (29.851 ms) : 0, 29851
GlobalTracer [baseline] (249.226 ms) : 0, 249226
GlobalTracer [candidate] (251.992 ms) : 0, 251992
AppSec [baseline] (32.275 ms) : 0, 32275
AppSec [candidate] (32.802 ms) : 0, 32802
Debugger [baseline] (60.586 ms) : 0, 60586
Debugger [candidate] (61.068 ms) : 0, 61068
Remote Config [baseline] (601.564 µs) : 0, 602
Remote Config [candidate] (757.976 µs) : 0, 758
Telemetry [baseline] (9.611 ms) : 0, 9611
Telemetry [candidate] (8.965 ms) : 0, 8965
Flare Poller [baseline] (3.644 ms) : 0, 3644
Flare Poller [candidate] (5.142 ms) : 0, 5142
section appsec
crashtracking [baseline] (1.245 ms) : 0, 1245
crashtracking [candidate] (1.232 ms) : 0, 1232
BytebuddyAgent [baseline] (686.404 ms) : 0, 686404
BytebuddyAgent [candidate] (678.796 ms) : 0, 678796
AgentMeter [baseline] (12.333 ms) : 0, 12333
AgentMeter [candidate] (12.248 ms) : 0, 12248
GlobalTracer [baseline] (250.497 ms) : 0, 250497
GlobalTracer [candidate] (249.355 ms) : 0, 249355
IAST [baseline] (24.305 ms) : 0, 24305
IAST [candidate] (24.269 ms) : 0, 24269
AppSec [baseline] (186.924 ms) : 0, 186924
AppSec [candidate] (186.575 ms) : 0, 186575
Debugger [baseline] (66.466 ms) : 0, 66466
Debugger [candidate] (65.801 ms) : 0, 65801
Remote Config [baseline] (591.0 µs) : 0, 591
Remote Config [candidate] (702.804 µs) : 0, 703
Telemetry [baseline] (7.89 ms) : 0, 7890
Telemetry [candidate] (7.809 ms) : 0, 7809
Flare Poller [baseline] (3.469 ms) : 0, 3469
Flare Poller [candidate] (3.434 ms) : 0, 3434
section iast
crashtracking [baseline] (1.228 ms) : 0, 1228
crashtracking [candidate] (1.263 ms) : 0, 1263
BytebuddyAgent [baseline] (810.058 ms) : 0, 810058
BytebuddyAgent [candidate] (816.379 ms) : 0, 816379
AgentMeter [baseline] (11.399 ms) : 0, 11399
AgentMeter [candidate] (11.476 ms) : 0, 11476
GlobalTracer [baseline] (239.843 ms) : 0, 239843
GlobalTracer [candidate] (240.902 ms) : 0, 240902
IAST [baseline] (30.952 ms) : 0, 30952
IAST [candidate] (29.397 ms) : 0, 29397
AppSec [baseline] (27.688 ms) : 0, 27688
AppSec [candidate] (28.74 ms) : 0, 28740
Debugger [baseline] (64.861 ms) : 0, 64861
Debugger [candidate] (66.468 ms) : 0, 66468
Remote Config [baseline] (535.184 µs) : 0, 535
Remote Config [candidate] (687.284 µs) : 0, 687
Telemetry [baseline] (7.773 ms) : 0, 7773
Telemetry [candidate] (7.77 ms) : 0, 7770
Flare Poller [baseline] (3.496 ms) : 0, 3496
Flare Poller [candidate] (3.489 ms) : 0, 3489
section profiling
crashtracking [baseline] (1.185 ms) : 0, 1185
crashtracking [candidate] (1.179 ms) : 0, 1179
BytebuddyAgent [baseline] (698.185 ms) : 0, 698185
BytebuddyAgent [candidate] (691.085 ms) : 0, 691085
AgentMeter [baseline] (8.959 ms) : 0, 8959
AgentMeter [candidate] (8.898 ms) : 0, 8898
GlobalTracer [baseline] (207.984 ms) : 0, 207984
GlobalTracer [candidate] (207.249 ms) : 0, 207249
AppSec [baseline] (32.546 ms) : 0, 32546
AppSec [candidate] (32.747 ms) : 0, 32747
Debugger [baseline] (66.101 ms) : 0, 66101
Debugger [candidate] (65.912 ms) : 0, 65912
Remote Config [baseline] (586.54 µs) : 0, 587
Remote Config [candidate] (709.164 µs) : 0, 709
Telemetry [baseline] (7.841 ms) : 0, 7841
Telemetry [candidate] (7.86 ms) : 0, 7860
Flare Poller [baseline] (3.488 ms) : 0, 3488
Flare Poller [candidate] (3.556 ms) : 0, 3556
ProfilingAgent [baseline] (93.449 ms) : 0, 93449
ProfilingAgent [candidate] (93.896 ms) : 0, 93896
Profiling [baseline] (94.015 ms) : 0, 94015
Profiling [candidate] (94.471 ms) : 0, 94471
LoadParameters
See matching parameters
SummaryFound 3 performance improvements and 0 performance regressions! Performance is the same for 18 metrics, 15 unstable metrics.
Request duration reports for insecure-bankgantt
title insecure-bank - request duration [CI 0.99] : candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section baseline
no_agent (1.236 ms) : 1224, 1247
. : milestone, 1236,
iast (3.317 ms) : 3272, 3363
. : milestone, 3317,
iast_FULL (6.085 ms) : 6023, 6147
. : milestone, 6085,
iast_GLOBAL (3.796 ms) : 3734, 3858
. : milestone, 3796,
profiling (2.224 ms) : 2203, 2244
. : milestone, 2224,
tracing (1.883 ms) : 1867, 1898
. : milestone, 1883,
section candidate
no_agent (1.239 ms) : 1227, 1250
. : milestone, 1239,
iast (3.298 ms) : 3250, 3347
. : milestone, 3298,
iast_FULL (6.208 ms) : 6144, 6272
. : milestone, 6208,
iast_GLOBAL (3.6 ms) : 3539, 3661
. : milestone, 3600,
profiling (2.188 ms) : 2169, 2207
. : milestone, 2188,
tracing (1.94 ms) : 1922, 1958
. : milestone, 1940,
Request duration reports for petclinicgantt
title petclinic - request duration [CI 0.99] : candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section baseline
no_agent (18.003 ms) : 17823, 18183
. : milestone, 18003,
appsec (20.048 ms) : 19844, 20251
. : milestone, 20048,
code_origins (17.675 ms) : 17503, 17848
. : milestone, 17675,
iast (17.912 ms) : 17736, 18088
. : milestone, 17912,
profiling (18.785 ms) : 18598, 18971
. : milestone, 18785,
tracing (18.288 ms) : 18106, 18470
. : milestone, 18288,
section candidate
no_agent (18.148 ms) : 17965, 18331
. : milestone, 18148,
appsec (18.723 ms) : 18529, 18916
. : milestone, 18723,
code_origins (18.123 ms) : 17943, 18304
. : milestone, 18123,
iast (18.013 ms) : 17833, 18193
. : milestone, 18013,
profiling (18.826 ms) : 18641, 19012
. : milestone, 18826,
tracing (17.883 ms) : 17707, 18058
. : milestone, 17883,
DacapoParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 11 metrics, 1 unstable metrics. Execution time for biojavagantt
title biojava - execution time [CI 0.99] : candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section baseline
no_agent (15.475 s) : 15475000, 15475000
. : milestone, 15475000,
appsec (14.621 s) : 14621000, 14621000
. : milestone, 14621000,
iast (18.473 s) : 18473000, 18473000
. : milestone, 18473000,
iast_GLOBAL (17.991 s) : 17991000, 17991000
. : milestone, 17991000,
profiling (15.013 s) : 15013000, 15013000
. : milestone, 15013000,
tracing (14.914 s) : 14914000, 14914000
. : milestone, 14914000,
section candidate
no_agent (15.006 s) : 15006000, 15006000
. : milestone, 15006000,
appsec (14.627 s) : 14627000, 14627000
. : milestone, 14627000,
iast (18.268 s) : 18268000, 18268000
. : milestone, 18268000,
iast_GLOBAL (17.848 s) : 17848000, 17848000
. : milestone, 17848000,
profiling (15.242 s) : 15242000, 15242000
. : milestone, 15242000,
tracing (14.695 s) : 14695000, 14695000
. : milestone, 14695000,
Execution time for tomcatgantt
title tomcat - execution time [CI 0.99] : candidate=1.62.0-SNAPSHOT~268fbea477, baseline=1.62.0-SNAPSHOT~9aedff24d2
dateFormat X
axisFormat %s
section baseline
no_agent (1.486 ms) : 1474, 1497
. : milestone, 1486,
appsec (3.829 ms) : 3606, 4052
. : milestone, 3829,
iast (2.277 ms) : 2208, 2347
. : milestone, 2277,
iast_GLOBAL (2.307 ms) : 2237, 2377
. : milestone, 2307,
profiling (2.088 ms) : 2033, 2143
. : milestone, 2088,
tracing (2.074 ms) : 2020, 2128
. : milestone, 2074,
section candidate
no_agent (1.486 ms) : 1474, 1498
. : milestone, 1486,
appsec (3.805 ms) : 3582, 4027
. : milestone, 3805,
iast (2.264 ms) : 2195, 2333
. : milestone, 2264,
iast_GLOBAL (2.306 ms) : 2237, 2376
. : milestone, 2306,
profiling (2.092 ms) : 2038, 2147
. : milestone, 2092,
tracing (2.071 ms) : 2018, 2125
. : milestone, 2071,
|
This file contains hidden or 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
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.
Investigation findings
When the RC
/v0.7/configendpoint returns HTTP 401, the call path terminates silently:DefaultConfigurationPoller.sendRequest()receives the 401response.isSuccessful()is false → the response body is logged via a rate-limited warning and the method returnshandleAgentResponse()is never calledRemoteConfigServiceImpl.accept()is never calledFeatureFlaggingGateway.dispatch(ServerConfiguration)is never calledDDEvaluator.accept()is never calledinitializationLatchnever counts downDDEvaluator.initialize()times out and returnsfalseProvider.initialize()throwsProviderNotReadyError— wrong state: should bePROVIDER_FATALFix
Added a
NonRetryableErrorListenerchain from the RC transport layer up to the OpenFeature provider:ConfigurationPoller(interface): addedaddNonRetryableErrorListener/removeNonRetryableErrorListenerdefault methods and theNonRetryableErrorListenerfunctional interfaceDefaultConfigurationPoller: implements the listener list;sendRequest()callsnotifyNonRetryableErrorListeners()whenresponse.code()is 401 or 403RemoteConfigServiceImpl: registers aNonRetryableErrorListenerthat forwards toFeatureFlaggingGateway.dispatchFatalError()FeatureFlaggingGateway: addedFatalErrorListenerinterface plusaddFatalErrorListener/removeFatalErrorListener/dispatchFatalError()— no OpenFeature SDK dependency (uses plainintfor status code)DDEvaluator: implementsFatalErrorListener; on receipt stores the error message and releasesinitializationLatch;initialize()checks for the fatal message after the latch releases and throwsFatalError, causing the OpenFeature SDK to setPROVIDER_FATALTest plan
feature-flagging-apiandremote-config-corestill pass/v0.7/configin the system test causes the provider to enterPROVIDER_FATALPROVIDER_READYPROVIDER_NOT_READY(latch not released,configuration.get()is null)Labels
tag: ai generatedtag: no release note