Add job query for no retries left

This pull request adds the job query for no retries left (retry=0) to the management service API and rest API. It is related to CAM-358.