Added functions for querying number of jobs for a specific task and
total number of tasks.