-
Notifications
You must be signed in to change notification settings - Fork 40.8k
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
Allow values from configtree to resolve nested placeholders #34195
Comments
Thanks for the suggestion. This is a little bit similar to #29642. A notable difference here, however, is that |
Thanks for the answer! Sounds legit to me. Surely it is not easy to to simply support this for all the various property source providers. Somehow it has to be unified how replacements can be performed with the different providers. I see minimum two ways to solve this: what do you think? |
We might be able to change |
We're going to try the |
I tried to use env variables in configtree in SB 3.2.5 and it does not seem to work unfortunately. Is there any progress at the moment? |
Not as yet I'm afraid @lazystone |
Ok, i understand the struggle here(we don't want to accidentally replace something in binary files), but I also realized that my problem was wrong from the beginning, so I'll describe it here for others. Initially we used configmaps in k8s environments to provide configuration overrides for SB. And standard way to pass secrets to it was to read them from k8s secrets, put them in environment variables and SB would resolve them later. Then, with introduction of configtree in SB we started to use it. And we did exactly the same thing as before - tried to use placeholders for secrets. One thing that we were missing I think - the whole purpose of configtree approach. Using configtree we could mount secrets as we mount configmaps in k8s pod and use them directly as configuration overrides. So, whoever faces this problem - have another look on your use case. Maybe you don't need this feature that much. |
See #40862 |
Superseded by #40862. |
…Sequence` but not `String` Fix spring-projectsGH-34195
Prompted by a review of #40862, I've realised that supporting this consistently isn't going to be straightforward. For example, It looks like a change in Framework may be a better option for fixing this consistently. spring-projects/spring-framework#32876 proposed a step in that direction, but it was declined. We'll discuss this with the Framework team and consider our options. |
It would be helpful if for properties which come from a configtree the placeholders will be replaced. Currently this seems to be blocked by the
ConfigTreePropertySource
producing nonString
results when getting the value of a property.The text was updated successfully, but these errors were encountered: