public void testEmptyCommits() throws Exception {
  clearIndexWithReplication();
  index(masterClient,"id","1","name","empty1");
  emptyUpdate(masterClient,"commit","true");
  pullFromMasterToSlave();
  rQuery(1,"name:empty1",slaveClient);
  assertVersions(masterClient,slaveClient);
  emptyUpdate(masterClient,"commit","true");
  pullFromMasterToSlave();
  index(masterClient,"id","2","name","empty2");
  emptyUpdate(masterClient,"commit","true");
  pullFromMasterToSlave();
  rQuery(1,"name:empty2",slaveClient);
  assertVersions(masterClient,slaveClient);
  index(masterClient,"id","3","name","empty3");
  emptyUpdate(masterClient,"commit","true","openSearcher","false");
  pullFromMasterToSlave();
  rQuery(0,"name:empty3",masterClient);
  rQuery(1,"name:empty3",slaveClient);
  index(masterClient,"id","4","name","empty4");
  emptyUpdate(masterClient,"commit","true");
  pullFromMasterToSlave();
  String q="name:(empty1 empty2 empty3 empty4)";
  rQuery(4,q,masterClient);
  rQuery(4,q,slaveClient);
  assertVersions(masterClient,slaveClient);
}

public void testEmptyCommits ( ) throws Exception { clearIndexWithReplication ( ) ; index ( masterClient , "id" , "1" , "name" , "empty1" ) ; emptyUpdate ( masterClient , "commit" , "true" ) ; pullFromMasterToSlave ( ) ; rQuery ( 1 , "name:empty1" , slaveClient ) ; assertVersions ( masterClient , slaveClient ) ; emptyUpdate ( masterClient , "commit" , "true" ) ; pullFromMasterToSlave ( ) ; index ( masterClient , "id" , "2" , "name" , "empty2" ) ; emptyUpdate ( masterClient , "commit" , "true" ) ; pullFromMasterToSlave ( ) ; rQuery ( 1 , "name:empty2" , slaveClient ) ; assertVersions ( masterClient , slaveClient ) ; index ( masterClient , "id" , "3" , "name" , "empty3" ) ; emptyUpdate ( masterClient , "commit" , "true" , "openSearcher" , "false" ) ; pullFromMasterToSlave ( ) ; rQuery ( 0 , "name:empty3" , masterClient ) ; rQuery ( 1 , "name:empty3" , slaveClient ) ; index ( masterClient , "id" , "4" , "name" , "empty4" ) ; emptyUpdate ( masterClient , "commit" , "true" ) ; pullFromMasterToSlave ( ) ; String q = "name:(empty1 empty2 empty3 empty4)" ; rQuery ( 4 , q , masterClient ) ; rQuery ( 4 , q , slaveClient ) ; assertVersions ( masterClient , slaveClient ) ; }
verify that empty commits and / or commits with opensearcher = false on the master do not cause subsequent replication problems on the slave
