static void failQuickInInitializationIfClusterAlreadyInInconsistentState(CassandraClientPool clientPool,CassandraKeyValueServiceConfig config){
  if (config.safetyDisabled()) {
    log.error("Skipped checking the cassandra cluster during initialization, because safety checks are" + " disabled. Please re-enable safety checks when you are outside of your unusual" + " migration period.");
    return;
  }
  String errorMessage="While checking the cassandra cluster during initialization, we noticed schema versions" + " could not settle. Failing quickly to avoid getting into harder to fix states (i.e. partially" + " applied patch upgrades, etc). This state is in rare cases the correct one to be in; for"+ " instance schema versions will be incapable of settling in a cluster of heterogenous"+ " Cassandra 1.2/2.0 nodes. If that is the case, disable safety checks in your Cassandra"+ " KVS preferences.";
  try {
    clientPool.run(null);
  }
 catch (  TException e) {
    throw new RuntimeException(errorMessage,e);
  }
catch (  IllegalStateException e) {
    log.error(errorMessage);
    throw e;
  }
}

static void failQuickInInitializationIfClusterAlreadyInInconsistentState ( CassandraClientPool clientPool , CassandraKeyValueServiceConfig config ) { if ( config . safetyDisabled ( ) ) { log . error ( "Skipped checking the cassandra cluster during initialization, because safety checks are" + " disabled. Please re-enable safety checks when you are outside of your unusual" + " migration period." ) ; return ; } String errorMessage = "While checking the cassandra cluster during initialization, we noticed schema versions" + " could not settle. Failing quickly to avoid getting into harder to fix states (i.e. partially" + " applied patch upgrades, etc). This state is in rare cases the correct one to be in; for" + " instance schema versions will be incapable of settling in a cluster of heterogenous" + " Cassandra 1.2/2.0 nodes. If that is the case, disable safety checks in your Cassandra" + " KVS preferences." ; try { clientPool . run ( null ) ; } catch ( TException e ) { throw new RuntimeException ( errorMessage , e ) ; } catch ( IllegalStateException e ) { log . error ( errorMessage ) ; throw e ; } }
this is a request from pbrown / fdes ; basically it ' s a pain to do db surgery to get out of failed patch upgrades , the majority of which requires schema mutations ; they would find it preferable to stop before starting the actual patch upgrade / setting applying state .
