)]}'
{
  "commit": "cc47d53d4870e2c285c3b72202ebe6f3fdd67b57",
  "tree": "f04d274fb0db78487095cda3ca21f85fd58936ef",
  "parents": [
    "cf510966724cb0963976c9d09aabfdd2bf32d8b6"
  ],
  "author": {
    "name": "Matthias Sohn",
    "email": "matthias.sohn@sap.com",
    "time": "Thu Mar 28 19:25:33 2024 +0100"
  },
  "committer": {
    "name": "Matthias Sohn",
    "email": "matthias.sohn@sap.com",
    "time": "Thu Mar 28 19:58:03 2024 +0100"
  },
  "message": "Destination#pushWasCanceled: minimize time spent in critical section\n\nWhen cancelling a push to a replication destination don\u0027t notify\nlisteners about not attempted push during the critical section where the\nstateLock is held but do this immediately after the critical section.\n\nWe observed in a high-availability setup with 2 primaries that\ncancelling a replication push blocked \u003e90 other threads trying to\nupdate some refs which tried to create new replication tasks via\nsynchronous events. Cancelling the push was stuck on visibility checks\ndone in EventBroker#fireEvent triggered by Destination#pushWasCanceled.\nThis visibility check was slow since the affected repository is huge\n(30GiB) and we use NFS for sharing repositories between primaries.\n\nMoving the call to PushOne#notifyNotAttempted outside the critical\nsection should reduce the impact of this critical section on other\nrequests updating refs concurrently.\n\nChange-Id: I085700c3f4cad95ef62521527ac4b920a59c76c2\nSigned-off-by: Matthias Sohn \u003cmatthias.sohn@sap.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "98170ae5cebacb5e1a202d1858702413a642a168",
      "old_mode": 33188,
      "old_path": "src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java",
      "new_id": "5316e35c966229d6358903dfa0fd0b704e7318ed",
      "new_mode": 33188,
      "new_path": "src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java"
    }
  ]
}
