Add spring.pid.fail-on-write-error support

Update `ApplicationPidFileWriter` to support a 'fail on write error'
properties which allows the user to exit the application if the PID
file cannot be written.

This commit also deprecates `spring.pidfile` in favor of
`spring.pid.file` so that the new property can be added without overlap.

Fixes gh-2764
This commit is contained in:
Tomasz Przybyła
2015-04-02 13:32:16 +02:00
committed by Phillip Webb
parent c13ff96b78
commit becced5f0b
5 changed files with 201 additions and 38 deletions

View File

@@ -612,7 +612,8 @@ content into your application; rather pick only the properties that you need.
management.security.sessions=stateless # session creating policy to use (always, never, if_required, stateless)
# PID FILE ({sc-spring-boot-actuator}/system/ApplicationPidFileWriter.{sc-ext}[ApplicationPidFileWriter])
spring.pidfile= # Location of the PID file to write
spring.pid.file= # Location of the PID file to write
spring.pid.fail-on-write-error= # Fail if the PID file cannot be written
# ENDPOINTS ({sc-spring-boot-actuator}/endpoint/AbstractEndpoint.{sc-ext}[AbstractEndpoint] subclasses)
endpoints.autoconfig.id=autoconfig