Store replication tasks instead of ref-update events

Fix the granularity of persistent events on disk by storing
replication tasks rather than ref-update events.

Ref-updates are triggering the replication tasks,
however it is tricky to perform reference counting on the associated
tasks reliably, due to all the different conditions of where a
replication task can be in the replication queue.

Fix a recurring issue on the persistence of ref-update events.
The persisted ref-update events were either removed prematurely on the
filesystem or left forever orphan even after the replication was completed
on all remotes and target URLs.
The problem was caused by the different granularity of the incoming
ref-update events and the corresponding replication tasks queued
and executed.

Do not persist ref-update events anymore but include remote and
target URLs at the replication tasks and persist those instead.

The stored objects are replication tasks and not anymore ref-update
events.

Bug: Issue 11172
Change-Id: I02d8cda0a124e8e3d2b9bb01b7d44f98ba717fcd
9 files changed
tree: 818618d94f92a7ac963b885eaf35ea31f14749dc
  1. .settings/
  2. src/
  3. .gitignore
  4. .mailmap
  5. BUILD
  6. LICENSE