implemented shareability between tasks, finished proper client closing