improve task archiver query performance