Page MenuHomePhabricator

Ignore repository versions on inactive devices in "Repository Servers" panel in Config
ClosedPublic

Authored by epriestley on Sep 5 2016, 5:39 PM.
Tags
None
Referenced Files
F13255467: D16492.id39690.diff
Sat, May 25, 5:27 AM
F13254614: D16492.id.diff
Sat, May 25, 3:33 AM
F13252543: D16492.id39689.diff
Sat, May 25, 1:41 AM
F13245883: D16492.diff
Thu, May 23, 6:25 AM
F13197516: D16492.diff
Mon, May 13, 12:14 AM
F13178794: D16492.diff
Wed, May 8, 8:41 PM
Unknown Object (File)
Apr 25 2024, 3:45 AM
Unknown Object (File)
Apr 16 2024, 2:49 PM
Subscribers
None

Details

Summary

Fixes T11590. Currently, we incorrectly consider cluster repository versions that are (or were) on devices which are no longer part of the active cluster service when building this status screen.

Instead, ignore them. This is just a display bug; the actual ClusterEngine already had similar logic.

Test Plan
  • Added a bad leader record to repository_workingcopyversion.
  • Before patch, got a bad "Partial (1w)" sync:

bad_partial.png (1×1 px, 177 KB)

  • After patch, got a good "Sycnchronized":

good_sync.png (1×1 px, 178 KB)

Diff Detail

Repository
rP Phabricator
Branch
clusterleader
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 13569
Build 17473: Run Core Tests
Build 17472: arc lint + arc unit

Event Timeline

epriestley retitled this revision from to Ignore repository versions on inactive devices in "Repository Servers" panel in Config.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.

This is just a display bug; the actual ClusterEngine already had similar logic.

This is not completely true: ClusterEngine is correct and this is just a display bug, but the ClusterEngine logic isn't that similar:

  • After a hosting change (observed to hosted or vice versa), we reset all the version clocks. This is fine/reasonable.
  • When synchronizing before a read, we examine all versions, but this is correct since we should fail if the leader somehow got deactivated.
  • When synchronizing before a write, we examine all versions, but this is correct since we should fail even if a deactivated node is holding a write lock.
  • We show all versions in DiffusionManage RepositoryStorage, but properly mark disabled nodes as disabled.
chad edited edge metadata.
This revision is now accepted and ready to land.Sep 5 2016, 6:06 PM
epriestley edited edge metadata.
  • Also fix a "cluter" -> "cluster" typo.
This revision was automatically updated to reflect the committed changes.