Skip to content

Commit

Permalink
Merge pull request #28488 from arend-von-reinersdorff
Browse files Browse the repository at this point in the history
* pr/28488:
  Polish "Clarify docs on JNDI properties in Servlet environment"
  Clarify docs on JNDI properties in Servlet environment

Closes gh-28488
  • Loading branch information
snicoll committed Jul 29, 2022
2 parents a6596e2 + 982d8ea commit 456c788
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
@@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -95,6 +95,8 @@ protected StandardServletEnvironment(MutablePropertySources propertySources) {
* {@link StubPropertySource stubs} at this stage, and will be
* {@linkplain #initPropertySources(ServletContext, ServletConfig) fully initialized}
* once the actual {@link ServletContext} object becomes available.
* <p>Addition of {@value #JNDI_PROPERTY_SOURCE_NAME} can be disabled with
* {@link JndiLocatorDelegate#IGNORE_JNDI_PROPERTY_NAME}.
* @see StandardEnvironment#customizePropertySources
* @see org.springframework.core.env.AbstractEnvironment#customizePropertySources
* @see ServletConfigPropertySource
Expand Down
6 changes: 3 additions & 3 deletions src/docs/asciidoc/core/core-beans.adoc
Expand Up @@ -9982,9 +9982,9 @@ is configured with two PropertySource objects -- one representing the set of JVM

NOTE: These default property sources are present for `StandardEnvironment`, for use in standalone
applications. {api-spring-framework}/web/context/support/StandardServletEnvironment.html[`StandardServletEnvironment`]
is populated with additional default property sources including servlet config and servlet
context parameters. It can optionally enable a {api-spring-framework}/jndi/JndiPropertySource.html[`JndiPropertySource`].
See the javadoc for details.
is populated with additional default property sources including servlet config, servlet
context parameters, and a {api-spring-framework}/jndi/JndiPropertySource.html[`JndiPropertySource`]
if JNDI is available.

Concretely, when you use the `StandardEnvironment`, the call to `env.containsProperty("my-property")`
returns true if a `my-property` system property or `my-property` environment variable is present at
Expand Down

0 comments on commit 456c788

Please sign in to comment.