release gateway when failed