use of org.neo4j.com.ProtocolVersion in project neo4j by neo4j.
the class MasterClientResolver method handle.
@Override
public void handle(ComException exception) {
exception.traceComException(log, "MasterClientResolver.handle");
if (exception instanceof IllegalProtocolVersionException) {
log.info("Handling " + exception + ", will pick new master client");
IllegalProtocolVersionException illegalProtocolVersion = (IllegalProtocolVersionException) exception;
ProtocolVersion requiredProtocolVersion = new ProtocolVersion(illegalProtocolVersion.getReceived(), ProtocolVersion.INTERNAL_PROTOCOL_VERSION);
getFor(requiredProtocolVersion);
} else if (exception instanceof InvalidEpochException) {
log.info("Handling " + exception + ", will go to PENDING and ask for election");
invalidEpochHandler.handle();
} else {
log.debug("Ignoring " + exception + ".");
}
}
Aggregations