Homestyx hydra

R1:2e09a93dc123

Improve efficiency of worker task GC for huge loads

Summary:
Fixes T9808.

An instance imported a very large repository, generating approximately 4 million tasks over the course of a few days. A week later, these tasks started expiring and became candidates for garbage collection.

The GC works by deleting 100 rows at at time over and over again. It finds the rows it's going to delete by querying for old rows.

Currently, this query generates a `WHERE dateCreated < X ORDER BY id DESC` query. This query…
Repository: R1 hydra
Commit Date: Nov 17 2015