4

Looking for way how to configure shutdown port in Spring boot app.

Ryanqy
  • 6,722
  • 3
  • 12
  • 23

1 Answers1

1

I don't think you can configure the spring-boot application this way, since it's very relative to the underlying container and this tomcat specific property is not added to the common application properties you are allowed to use.

Another solution is to use spring boot actuator endpoint instead. It has a shutdown endpoint for such a tasks. All you need is to use spring-actuator and enable this endpoint, since it's disabled by default.

Here is yet another SO question, you may find useful though it's unanswered, about the way to shutdown spring boot application.

Community
  • 1
  • 1
Stanislav
  • 24,169
  • 8
  • 72
  • 72