Skip to content
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

Doc: Spring Active Profile order of evaluation is unclear [SPR-13845] #18418

spring-projects-issues opened this issue Jan 7, 2016 · 1 comment
type: task A general task


Copy link

spring-projects-issues commented Jan 7, 2016

Prashant Deva opened SPR-13845 and commented

In the docs here , it is unclear what the order of evaluation of active spring profiles is:

If i specify the active profiles on:

  1. the 'command line' eg"mango, orange" and
  2. my web.xml has active profiles listed as apples

Do the final active profiles contain:

  1. apples or
  2. mango, orange
  3. apples, mango, orange

Affects: 4.2.4

Copy link
Collaborator Author

spring-projects-issues commented Jan 20, 2016

Juergen Hoeller commented

In your scenario, the active profiles will be apples, due to the servlet context property source (web.xml context-param entries) overriding system properties (as provided by the command line). Such property values do not get merged but rather completely override each other according to the property source precedence hierarchy.

I've added a corresponding paragraph to the reference documentation, summarizing the details given in StandardServletEnvironment's javadoc and related places.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
type: task A general task
None yet

No branches or pull requests

2 participants