Hardening/576 ordered shutdown to avoid false leaks

### Description
Intent to fix false leaks reported by valgrind using a more graceful exit of the broker after receiving the '/exit' REST request.