Claus Ibsen created CAMEL-27805:
-----------------------------------
Summary: camel-openfeature: stopping the component shuts down a
user provider bean, options of a second endpoint for a domain are ignored
Key: CAMEL-27805
URL: https://issues.apache.org/jira/browse/CAMEL-27805
Project: Camel
Issue Type: Bug
Components: camel-openfeature
Reporter: Claus Ibsen
Fix For: 4.25.0
Found while improving the option descriptions of camel-openfeature for
CAMEL-23832 (pull request https://github.com/apache/camel/pull/31138).
These are separate problems of the component; the descriptions change only
documents the current behavior.
h4. 1. Stopping the component shuts down a provider it does not own
{{OpenFeatureComponent.doStop}} calls {{localApi.shutdown()}}, which shuts down
every registered provider, including a user FeatureProvider bean (from
{{provider}} or the {{flags}} bean) that Camel marks owned=false;
{{unregisterEndpoint}} only drops Camel's binding. A bean shared with the
application is shut down, and after a CamelContext stop/start a FlagdProvider
bean skips initialize and stays shut down.
Proposed change: register non-owned providers through a wrapper whose shutdown
does nothing, or do not shut them down.
h4. 2. Provider options of a second endpoint for the same domain are ignored
{{OpenFeatureComponent.acquireOrRegister}} reuses the binding of the first
endpoint of a domain and silently ignores provider, flags, flagsResource, host,
port, tls, certPath and deadline of the next ones.
Proposed change: WARN or fail when they differ.
h4. 3. deadline <= 0
validate() does not check deadline; 0 or less makes FlagdProvider.initialize
time out at once and the endpoint fails to start.
_Claude Code on behalf of davsclaus_
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)