Skip to content

Commit c5e14a8

Browse files
committed
Merge pull request #18581 from polarbear567
* pr/18581: Polish "Add metadata entry for spring.main.register-shutdown-hook" Add metadata entry for spring.main.register-shutdown-hook Closes gh-18581
2 parents 34287fd + 22f4491 commit c5e14a8

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

spring-boot-project/spring-boot-docs/src/main/asciidoc/appendix-application-properties.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ Rather, pick only the properties that you need.
120120
# APPLICATION SETTINGS ({spring-boot-module-code}/SpringApplication.java[SpringApplication])
121121
spring.main.allow-bean-definition-overriding=false # Whether bean definition overriding, by registering a definition with the same name as an existing definition, is allowed.
122122
spring.main.banner-mode=console # Mode used to display the banner when the application runs.
123+
spring.main.register-shutdown-hook=true # Whether the application should have a shutdown hook registered.
123124
spring.main.sources= # Sources (class names, package names, or XML resource locations) to include in the ApplicationContext.
124125
spring.main.web-application-type= # Flag to explicitly request a specific type of web application. If not set, auto-detected based on the classpath.
125126

spring-boot-project/spring-boot/src/main/resources/META-INF/additional-spring-configuration-metadata.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -607,6 +607,13 @@
607607
"description": "Mode used to display the banner when the application runs.",
608608
"defaultValue": "console"
609609
},
610+
{
611+
"name": "spring.main.register-shutdown-hook",
612+
"type": "java.lang.Boolean",
613+
"sourceType": "org.springframework.boot.SpringApplication",
614+
"description": "Whether the application should have a shutdown hook registered.",
615+
"defaultValue": true
616+
},
610617
{
611618
"name": "spring.main.show-banner",
612619
"type": "java.lang.Boolean",

0 commit comments

Comments
 (0)