You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Konrad Windszus (Jira)" <ji...@apache.org> on 2021/02/02 12:27:00 UTC
[jira] [Commented] (FELIX-6384) Felix Configadmin Interpolator:
Support default directive with empty value
[ https://issues.apache.org/jira/browse/FELIX-6384?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17277081#comment-17277081 ]
Konrad Windszus commented on FELIX-6384:
----------------------------------------
PR in https://github.com/apache/felix-dev/pull/69.
> Felix Configadmin Interpolator: Support default directive with empty value
> --------------------------------------------------------------------------
>
> Key: FELIX-6384
> URL: https://issues.apache.org/jira/browse/FELIX-6384
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Affects Versions: configadmin-interpolation-plugin-1.1.0
> Reporter: Konrad Windszus
> Priority: Major
>
> Currently in https://github.com/apache/felix-dev/tree/master/configadmin-plugins/interpolation#default-values it is not stated that an empty value is not supported as default value. Still the following code is not replaced as expected
> {code}
> $[env:NON_EXISTING_VAR;default=]
> {code}
> This is due to the parsing logic in https://github.com/apache/felix-dev/blob/0aa232a4ff8f95e92d947027ac7d8010e2a0e142/configadmin-plugins/interpolation/src/main/java/org/apache/felix/configadmin/plugin/interpolation/Interpolator.java#L118 which detects the directive (in this case {{default}}) only in case there is at least one character after the {{=}}.
> This limitation should be lifted to also allow empty values as default values. At the same time values containing the character {{=}} should be allowed as well.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)