dcapwell commented on code in PR #47:
URL: https://github.com/apache/cassandra-accord/pull/47#discussion_r1205800372
##########
accord-core/src/main/java/accord/topology/TopologyManager.java:
##########
@@ -223,14 +237,14 @@ public TopologyManager(TopologySorter.Supplier sorter, Id
node)
{
this.sorter = sorter;
this.node = node;
- this.epochs = new Epochs(new EpochState[0]);
+ this.epochs = Epochs.EMPTY;
}
public synchronized void onTopologyUpdate(Topology topology)
{
Epochs current = epochs;
- checkArgument(topology.epoch == current.nextEpoch());
+ checkArgument(topology.epoch == current.nextEpoch() || epochs ==
Epochs.EMPTY);
Review Comment:
```suggestion
checkArgument(topology.epoch == current.nextEpoch() || epochs ==
Epochs.EMPTY, "Unexpected epoch %d; expected %d", topology.epoch,
current.nextEpoch();
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]