Add support to kill instance when required