Description
Executable JAR created by tomcat7-maven-plugin:exec-war-only does not call ServletContextListener.contextDestroyed() callback method when Java process is killed or when Ctrl + C is pressed. There is no way to cleanly shutdown web application.
The same application (attached) deployed on standalone Tomcat works just fine. Hitting Ctrl + C correctly undeploys and shuts down application.
Build attached application and run java -jar target/standalone.jar. Ctrl + C kills the process immediately. On the other hand {standalone.war}} deployed to normal Tomcat under /webapps shuts down correctly and we can see log statement from contextDestroyed().