Add the cancelShutDownTimer hook

Add the cancelShutDownTimer hook,  lets coders can call it to cancel off
the default timer, and completely shutdown the server manually.
Merge pull request #644 from Cosmosbox/master

Add the cancelShutDownTimer hook