If user runs an executable archive then it and its lib directory will be
on the classpath. Entries from loader.path take precedence in a way that
should make sense to users (earlier wins like in CLASSPATH env var).
Also added new integration tests to verify the behaviour (big improvement
on the old ones, which probably aought to be beefed up to the same
standard).
Fixes gh-2314
The "Customizing ConfigurableEmbeddedServletContainer directly"
section should use `HttpStatus.NOT_FOUND` and not `HttpStatus.404` in
the sample code.
Fixes gh-2258
Health indicator configuration keys have moved from the health.* to the
management.health.* namespace. This commit makes sure that these are
documented properly in 1.1.x as well.
See gh-2118
In a properties file, a backslash is used as an escape character for
the line terminator sequence to allow values to be split across
multiple lines. When a backslash is used elsewhere they're stripped
out of the property's value.
This commit updates .properties-based examples for configuring
server.tomcat.internal-proxies to escape the backslahes so that they
are retained in the property's value at runtime.
See gh-1989
Fixes a couple of typos in the documentation:
* `x-forwarded-protocol` is not the standard name for this header
* `require_https` is not an existing property, but rather `require_ssl`
If a Gradle build is using the Spring Boot Gradle plugin's support for
declaring dependencies without versions then they will be unable to
publish Maven artifacts from the build as the Gradle-generated pom
will fail to validate. This is because Gradle doesn't apply the
Boot-provided dependency versions to the dependencies in the generated
pom.
This can be addressed by configuring Gradle to generate a pom that
either imports spring-boot-dependencies into its dependency management
or that uses spring-boot-starter-parent as its parent. This commit
updates the documentation to document the need for this configuration
and to provide examples of how to do so.
Closes gh-1806
Traditionally, a @ServerEndpoint-annotated bean is found by a servlet
container initialiser, however Boot does not run servlet container
initialisers when an embedded container is being used. To be able to use
@ServerEndpoint in a Boot app that uses embedded Tomcat a
ServerEndpointExporter bean must be declared.
This commit updates the documentation to describe this requirement and
also updates the WebSockets sample to illustrate the use of
ServerEndpointExporter. The version of Spring Framework has been updated
to 4.0.8.BUILD-SNAPSHOT. This picks up the fix for SPR-12340.
Closes gh-1722
In some scenarios, the ErrorPageFilter will want to forward the request
to an error page but the response has already been committed. One common
cause of this is when the filter’s running on WAS. WAS calls
flushBuffer() (which commits the response), upon a clean exit from a
servlet’s service method.
Previously, the filter would attempt the forward, even if the response
was committed. This would result in an IllegalStateException and a
possibly incomplete response that may also have an incorrect status
code.
This commit updates the ErrorPageFilter to check to see if the response
has already been committed before it attempts to forward the request to
the error page. If the response has already been committed, the filter
logs an error and allows the container’s normal handling to kick in.
This prevents an IllegalStateException from being thrown.
This commit also updates the response wrapper to keep track of when
sendError has been called. Now, when flushBuffer is called, if
sendError has been called, the wrapper calls sendError on the wrapped
response. This prevents the wrapper from suppressing an error when the
response is committed before the request handling returns to the error
page filter.
Closes gh-1575
Corrected the documentation to refer to file as tests.groovy, rather
than test.groovy. Updated cope snippet as tests.groovy should expect
"Hello World!" rather than "Hello World".
Closes gh-1593