How to terminate a web service