Added logging functions to Task