//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void masterRejoinsAfterFailureAndReelection() throws Throwable //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void MasterRejoinsAfterFailureAndReelection() { // Given HighlyAvailableGraphDatabase initialMaster = _cluster.Master; // When _cluster.info("Fail master"); ClusterManager.RepairKit kit = _cluster.fail(initialMaster); _cluster.info("Wait for 2 to become master and 3 slave"); _cluster.await(masterAvailable(initialMaster)); _cluster.await(masterSeesSlavesAsAvailable(1)); _cluster.info("Repair 1"); kit.Repair(); // Then _cluster.info("Wait for cluster recovery"); _cluster.await(masterAvailable()); _cluster.await(allSeesAllAsAvailable()); assertEquals(3, _cluster.size()); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void shouldHandleSlaveCommittingLargeTx() public virtual void ShouldHandleSlaveCommittingLargeTx() { // GIVEN GraphDatabaseService slave = Cluster.AnySlave; long initialNodeCount = NodeCount(slave); // WHEN Cluster.info("Before commit large"); int nodeCount = CommitLargeTx(slave); Cluster.info("Before sync"); Cluster.sync(); Cluster.info("After sync"); // THEN all should have that tx AssertAllMembersHasNodeCount(initialNodeCount + nodeCount); // and if then master commits something, they should all get that too Cluster.info("Before commit small"); CommitSmallTx(Cluster.Master); Cluster.info("Before sync small"); Cluster.sync(); Cluster.info("After sync small"); AssertAllMembersHasNodeCount(initialNodeCount + nodeCount + 1); }