mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Jean-Noel Rouvignac
20.14.2014 5eb7b26eabf15d047fd913597aa508bb78c1d7e7
refs
author Jean-Noel Rouvignac <jean-noel.rouvignac@forgerock.com>
Tuesday, May 20, 2014 12:14 +0200
committer Jean-Noel Rouvignac <jean-noel.rouvignac@forgerock.com>
Tuesday, May 20, 2014 12:14 +0200
commit5eb7b26eabf15d047fd913597aa508bb78c1d7e7
tree d8654f09a0abe68b3a456f3aaa1c1240a9b659f8 tree | zip | gz
parent bc22107711f86a81958b70069f509dbe865a9559 view | diff
OPENDJ-1259 (CR-3563) Make the Medium Consistency Point support replicas temporarily leaving the topology


Added more tests about how changeNumber computation is performed WRT replicas offline messages and RS restarts.


ChangeNumberIndexerTest.java:
Tested additional scenarios: emptyDBTwoDSsOneInitiallyOffline(), emptyDBTwoDSsOneInitiallyWithChangesThenOffline(), emptyDBTwoDSsOneInitiallyPersistedOfflineThenChanges().
In several tests, called assertExternalChangelogContent() after calling startCNIndexer().
Renamed setDBInitialRecords() to setCNIndexDBInitialRecords().
Added more javadocs.
Used @Mock + MockitoAnnotations.initMocks() instead of several calls to Mockito.mock().

ChangeNumberIndexer.java:
Changed the code to support the additional scenarios.
Renamed allInitialReplicasArePastOldestPossibleCSN() to allInitialReplicasAreOfflineOrAlive().
Changed removeCursor() into getCursor().
2 files modified
259 ■■■■ changed files
opends/src/server/org/opends/server/replication/server/changelog/je/ChangeNumberIndexer.java 77 ●●●● diff | view | raw | blame | history
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/changelog/je/ChangeNumberIndexerTest.java 182 ●●●●● diff | view | raw | blame | history