scottfrederick / cf-shutdown-hook Goto Github PK
View Code? Open in Web Editor NEWThis app demonstrates graceful shutdown of an app running in Cloud Foundry.
This app demonstrates graceful shutdown of an app running in Cloud Foundry.
Hi Scott,
Appreciate nice clean example.
Are you aware that there is a 10 second override? Predestroy needs to be finished in 10 seconds otherwise application exits anyways :-(
Do you have any idea/suggestion about overriding it?
I changed you code to start the count down at 19 and this is what happened
2016-01-23T07:06:31.35-0600 [APP] OUT 2016-01-23 13:06:31.355 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Initiating graceful shutdown
2016-01-23T07:06:31.35-0600 [APP] OUT 2016-01-23 13:06:31.356 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 19 seconds
2016-01-23T07:06:32.35-0600 [APP] OUT 2016-01-23 13:06:32.356 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 18 seconds
2016-01-23T07:06:33.35-0600 [APP] OUT 2016-01-23 13:06:33.356 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 17 seconds
2016-01-23T07:06:34.35-0600 [APP] OUT 2016-01-23 13:06:34.357 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 16 seconds
2016-01-23T07:06:35.35-0600 [APP] OUT 2016-01-23 13:06:35.357 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 15 seconds
2016-01-23T07:06:36.35-0600 [APP] OUT 2016-01-23 13:06:36.358 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 14 seconds
2016-01-23T07:06:37.35-0600 [APP] OUT 2016-01-23 13:06:37.358 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 13 seconds
2016-01-23T07:06:38.35-0600 [APP] OUT 2016-01-23 13:06:38.359 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 12 seconds
2016-01-23T07:06:39.35-0600 [APP] OUT 2016-01-23 13:06:39.359 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 11 seconds
2016-01-23T07:06:40.36-0600 [APP] OUT 2016-01-23 13:06:40.359 INFO 14 --- [ Thread-3] o.c.s.shutdown.web.LifecycleComponent : Shutting down in 10 seconds
2016-01-23T07:06:41.32-0600 [API] OUT Updated app with guid 5df203f0-48ae-4e2e-88fe-c60d7fc3520a ({"state"=>"STOPPED"})
2016-01-23T07:06:41.34-0600 [APP] OUT Exit status 255
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.