Esempio n. 1
0
def dupes_process_hashkey(hashkey, cliargs):
    """This is the duplicate file worker function.
    It processes hash keys in the dupes Queue.
    """
    from diskover_dupes import populate_hashgroup, verify_dupes, index_dupes
    # find all files in ES matching hashkey
    hashgroup = populate_hashgroup(hashkey, cliargs)
    # process the duplicate files in hashgroup
    hashgroup = verify_dupes(hashgroup, cliargs)
    if hashgroup:
        index_dupes(hashgroup, cliargs)
Esempio n. 2
0
def dupes_process_hashkeys(hashgroups, cliargs):
    """This is the duplicate file worker function.
    It processes file hash keys in the dupes Queue.
    """
    from diskover_dupes import verify_dupes, index_dupes

    for filehash_filelist in hashgroups:
        # process the duplicate files in hashgroup
        dupes = verify_dupes(filehash_filelist, cliargs)
        if dupes:
            index_dupes(dupes, cliargs)
Esempio n. 3
0
def dupes_process_hashkey(hashkey, cliargs):
    """This is the duplicate file worker function.
    It processes hash keys in the dupes Queue.
    """
    import diskover_dupes
    bot_logger.info('*** Processing Hash Key: ' + hashkey)
    jobstart = time.time()
    # find all files in ES matching hashkey
    hashgroup = diskover_dupes.populate_hashgroup(hashkey, cliargs)
    # process the duplicate files in hashgroup
    hashgroup = diskover_dupes.verify_dupes(hashgroup, cliargs)
    if hashgroup:
        diskover_dupes.index_dupes(hashgroup, cliargs)
    elapsed_time = round(time.time() - jobstart, 3)
    bot_logger.info('*** FINISHED JOB, Elapsed Time: ' + str(elapsed_time))