Rewarded force-close mechanism to eliminate stale allocations

I agree with Zac about how this could be solved with more significant queries: more fluid and accurate signals for indexers as well as rebate pool motivation to stay within the maximum epoch limit

It makes sense to limit the keeper role to the indexer’s delegators, other indexers, and the subgraph owner (Does dApps know which indexer served them data?) OR, let closing stale allocations still cost something to the Keeper even after gas-cost compensation, and whoever’s incentive for rewards outweighs the cost can force-close.

Grace period is sort of iffy to determine. If an indexer relies on indexer software (which I hope they do) and there’s a subgraph that failed undeterministically such that agent cannot close, then how do we tell if an indexer has forgotten about it or if they are planning to manually grab the valid POIs?
This is where ‘grace period’ makes sense to me, but the indexer software do reallocation the epoch before it becomes stale and so the indexer would have 1 epoch to do manual allocation before ‘stale’

Some similar ideas here Allow multiple undelegation request from a delegator - #2 by That3Percent


nit-picking

=> currentEpoch - (createdAtEpoch + maxAllocationEpochs)?


Another thing I was wondering, if the indexer neglected all operations completely, all of their allocations are stale (say if the weighted average age > 28 epochs), maybe we can use the batch closeAllocationsMany to shut down all their stale allocations?