BacklinkCache::partition() is persistently cached with an expiry time
of one hour, with no invalidation. If a page starts using a template
after the partition cache is saved, and its page_id happens to fall in
a gap between batch ranges, a subsequent update to the template would
miss the page. Its page_touched would be permanently incorrect.
So, when loading the page IDs in a batch, use the start of the next
batch as the endpoint, rather than the highest page ID at the time of
the cache update.
Change-Id: I4459fc1c4242cd59505f0e05bf5c20a0b96cab33