Page MenuHomePhabricator

D16492.id39690.diff
No OneTemporary

D16492.id39690.diff

diff --git a/src/applications/config/controller/PhabricatorConfigClusterRepositoriesController.php b/src/applications/config/controller/PhabricatorConfigClusterRepositoriesController.php
--- a/src/applications/config/controller/PhabricatorConfigClusterRepositoriesController.php
+++ b/src/applications/config/controller/PhabricatorConfigClusterRepositoriesController.php
@@ -153,6 +153,14 @@
$versions = idx($repository_versions, $repository_phid, array());
+ // Filter out any versions for devices which are no longer active.
+ foreach ($versions as $key => $version) {
+ $version_device_phid = $version->getDevicePHID();
+ if (empty($active_devices[$version_device_phid])) {
+ unset($versions[$key]);
+ }
+ }
+
$leaders = 0;
foreach ($versions as $version) {
if ($version->getRepositoryVersion() == $leader_version) {
diff --git a/src/applications/diffusion/protocol/DiffusionRepositoryClusterEngine.php b/src/applications/diffusion/protocol/DiffusionRepositoryClusterEngine.php
--- a/src/applications/diffusion/protocol/DiffusionRepositoryClusterEngine.php
+++ b/src/applications/diffusion/protocol/DiffusionRepositoryClusterEngine.php
@@ -104,7 +104,7 @@
// We identify all the cluster leaders and reset their version to 0.
// We identify all the cluster followers and demote them.
- // This allows the cluter to start over again at version 0 but keep the
+ // This allows the cluster to start over again at version 0 but keep the
// same leaders.
if ($versions) {

File Metadata

Mime Type
text/plain
Expires
Sun, Nov 3, 1:58 AM (2 w, 1 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6727442
Default Alt Text
D16492.id39690.diff (1 KB)

Event Timeline