Skip to content

Conversation

quaff
Copy link
Contributor

@quaff quaff commented Mar 25, 2025

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Mar 25, 2025
@wilkinsona
Copy link
Member

Thanks for the suggestion but I think this may cause confusion. , isn't really the equivalent of |. It's a separator for the expressions when configured as a single comma-separate value due to it being bound to a String[]. If it's configured as a list, no separation occurs. In other words, the following two snippets of YAML are not equivalent:

spring.config.activate.on-profile:
    - a|b
spring.config.activate.on-profile:
    - a,b

I think it would be better to update the table in this section of the documentation to describe on-profile more accurately. Perhaps something like "profile expressions of which at least one must match for the document to be active".

@wilkinsona wilkinsona added the status: waiting-for-feedback We need additional information before we can continue label Mar 25, 2025
@quaff
Copy link
Contributor Author

quaff commented Mar 26, 2025

Updated, could someone review the wording?

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Mar 26, 2025
@snicoll snicoll changed the title Clarify the comma in "spring.config.activate.on-profile" value and add test Clarify the use of multiple profile expressions with "spring.config.activate.on-profile" Apr 17, 2025
@snicoll snicoll added type: documentation A documentation update and removed status: waiting-for-triage An issue we've not yet triaged status: feedback-provided Feedback has been provided labels Apr 17, 2025
@snicoll snicoll self-assigned this Apr 17, 2025
@snicoll snicoll added this to the 3.3.11 milestone Apr 17, 2025
snicoll pushed a commit that referenced this pull request Apr 17, 2025
This commit clarifies the semantic of declaring multiple profile
expression with the "spring.config.activate.on-profile" property.

See gh-44866

Signed-off-by: Yanming Zhou <[email protected]>
@snicoll snicoll closed this in ad61236 Apr 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: documentation A documentation update

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants