RuntimeException cause = new RuntimeException( "Unable to get master from ZK" );
shutdown( cause, false );
throw cause;
}
XaDataSource nioneoDataSource = getConfig().getTxModule()
.getXaDataSourceManager().getXaDataSource( Config.DEFAULT_DATA_SOURCE_NAME );
long myLastCommittedTx = nioneoDataSource.getLastCommittedTxId();
long highestCommonTxId = Math.min( myLastCommittedTx, master.other().getLastCommittedTxId() );
int masterForMyHighestCommonTxId = -1;
try
{
masterForMyHighestCommonTxId = nioneoDataSource.getMasterForCommittedTx( highestCommonTxId );;
}
catch ( IOException e )
{
// This is quite dangerous to just catch here... but the special case is
// where this db was just now copied from the master where there's data,