Remove replication events clustering

Replication events clustering is still a work in progress and it is
causing an elevated number of scheduled replication events which is
flooding this dual-master instance peers.

As an example, updating the user Settings' status on a gerrit instance
replicating to a filesystem target configured with a
distributionInterval of 1 causes a scheduling of 6 replication tasks,
as such:

```
[2020-09-02 18:27:09,615] scheduling replication
  All-Users:refs/users/00/1000000 =>
  file:///tmp/gerrit_setup/instance-2/git/All-Users.git
  [CONTEXT PLUGIN="replication" ]

[2020-09-02 18:27:09,616] scheduled
   All-Users:refs/users/00/1000000 => [fcbdeafa]
   push file:///tmp/gerrit_setup/instance-2/git/All-Users.git
   to run after 5s [CONTEXT PLUGIN="replication" ]
```

This in turn, causes the emission of 6 ref-replication-scheduled events:

```
{
   "project":"All-Users",
   "ref":"refs/users/00/1000000",
   "targetNode":"/tmp/gerrit_setup/instance-2/git/All-Users.git",
   "type":"ref-replication-scheduled",
   "eventCreatedOn":1599063267
}
```

Remove shared events and  volume so that only the active master is in
charge of replication. Turn off replication distributor, accordingly.

Bug: Issue 13346
Change-Id: Iee877729a72ee936a8a940abc90ed90879258829
diff --git a/dual-master/cf-cluster.yml b/dual-master/cf-cluster.yml
index f2bb08c..fd39589 100644
--- a/dual-master/cf-cluster.yml
+++ b/dual-master/cf-cluster.yml
@@ -145,7 +145,6 @@
           done; (exit $s)
           mkdir -p $DIR_TGT/git
           mkdir -p $DIR_TGT/high-availability
-          mkdir -p $DIR_TGT/events
           chown -R 1000:1000 $DIR_TGT
           cp -p /etc/fstab /etc/fstab.back-$(date +%F)
           echo -e \"$DIR_SRC:/ \t\t $DIR_TGT \t\t nfs \t\t defaults \t\t 0 \t\t 0\" | tee -a /etc/fstab
diff --git a/dual-master/cf-service-master.yml b/dual-master/cf-service-master.yml
index 77c867f..1f61c3b 100644
--- a/dual-master/cf-service-master.yml
+++ b/dual-master/cf-service-master.yml
@@ -161,7 +161,6 @@
   Gerrit:
     Volume:
       Git: gerrit-git-master
-      Events: gerrit-events-master
       Websessions: gerrit-ha-websessions-master
       Data: gerrit-data-master
       Index: gerrit-index-master
@@ -300,8 +299,6 @@
                       ContainerPath: /var/gerrit/db
                     - SourceVolume: !Join ['-', [!FindInMap ['Gerrit', 'Volume', 'Logs'], !Ref 'GerritInstanceNumber']]
                       ContainerPath: /var/gerrit/logs
-                    - SourceVolume: !Join ['-', [!FindInMap ['Gerrit', 'Volume', 'Events'], !Ref 'GerritInstanceNumber']]
-                      ContainerPath: /var/gerrit/events
                   Cpu: !Ref GerritCPU
                   Memory: !Ref GerritRAM
                   PortMappings:
@@ -321,9 +318,6 @@
               - Name: !FindInMap ['Gerrit', 'Volume', 'Git']
                 Host:
                   SourcePath: "/mnt/efs/gerrit-shared/git"
-              - Name: !Join ['-', [!FindInMap ['Gerrit', 'Volume', 'Events'], !Ref 'GerritInstanceNumber']]
-                Host:
-                  SourcePath: "/mnt/efs/gerrit-shared/events"
               - Name: !FindInMap ['Gerrit', 'Volume', 'Websessions']
                 Host:
                   SourcePath: "/mnt/efs/gerrit-shared/high-availability"
diff --git a/gerrit/etc/replication.config.template b/gerrit/etc/replication.config.template
index 94ef52f..f2216a3 100644
--- a/gerrit/etc/replication.config.template
+++ b/gerrit/etc/replication.config.template
@@ -1,8 +1,6 @@
 [replication]
   lockErrorMaxRetries = 30
   maxRetries = 30
-  eventsDirectory = events
-  distributionInterval = 1
 
 [gerrit]
   autoReload = true