advancedCache(0).lock(KEY);
sequencer.exit("tx:perform_op");
}
private void startRebalance() throws Exception {
InvocationMatcher rebalanceCompletedMatcher = matchMethodCall("handleRebalanceCompleted")
.withParam(1, address(2)).build();
advanceOnGlobalComponentMethod(sequencer, manager(0), ClusterTopologyManager.class,
rebalanceCompletedMatcher).before("rebalance:before_confirm");
InvocationMatcher localRebalanceMatcher = matchMethodCall("handleRebalance").build();
advanceOnGlobalComponentMethod(sequencer, manager(2), LocalTopologyManager.class,
localRebalanceMatcher).before("rebalance:before_get_tx").after("rebalance:after_get_tx");
consistentHashFactory.setOwnerIndexes(2, 1);
consistentHashFactory.triggerRebalance(cache(0));
}