Sorting using job => dependency relationship