Add OptimizeRepository RPC
fixes: #2653 (closed)
This MR adds an OptimizeRepository
RPC that calls the optimizeRepository
helper. This needs to be a separate RPC instead of having ReplicateRepository
call optimizeRepository
directly because ReplicateRepository
can happen before object pools get linked, and so we might end up calling optimizeRepository
on a object-pool linked repository. (see discussion in !1981 (comment 332544003))
So we need a separate RPC for this, and we can add this as a replication job type so then it happens after the entire replication (which will include object pool linking)