Stopping hook
Refactor server