• Guido Trotter's avatar
    Don't lock on QueryJobs, by using the disk version · 9f7b4967
    Guido Trotter authored
    
    
    We move from querying the in-memory version to loading all jobs from the
    disk. Since the jobs are written/deleted on disk in an atomic manner, we
    don't need to lock at all. Also, since we're just looking at the
    contents of a directory, we don't need to check that the job queue is
    "open".
    
    If some jobs are removed between when we listed them and us loading
    them, we need to be able to cope: if we were asked to load those jobs
    specifically, we must report the failure, but if we were just asked to
    "load all" we shall just not consider them as part of the "all" set,
    since they were deleted.
    Signed-off-by: default avatarGuido Trotter <ultrotter@google.com>
    Reviewed-by: default avatarIustin Pop <iustin@google.com>
    9f7b4967
jqueue.py 42.9 KB