Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to shutdown dropwizard application?

I am trying to come up with a microservice using dropwizard. The documentation tells how to start the application, but says nothing about terminating it gracefully. Fir example, apache tomcat has both startup and shutdown scripts.

So does anyone know how to terminate a dropwizard application other than pressing Ctrl+C of kill ?

like image 931
Amit Sharma Avatar asked Dec 01 '22 18:12

Amit Sharma


1 Answers

Dropwizard Jetty has shutdown hooks. So kill -SIGINT <pid> works out really well.

like image 183
Amit Sharma Avatar answered Dec 03 '22 07:12

Amit Sharma