added shutdown method in handler