Exemplo n.º 1
0
  @After
  public void tearDown() throws InterruptedException {
    masterClientRunner.stop();
    masterSlaveRunner.stop();

    for (ServerRunner slaveRunner : slaveRunners.values()) {
      slaveRunner.stop();
    }

    client = null;
    master = null;
    slaveRunners = null;
  }
Exemplo n.º 2
0
 protected void stopSlave(String name) throws InterruptedException {
   ServerRunner sr = slaveRunners.get(name);
   if (sr == null) {
     throw new RuntimeException("Slave does not exist!");
   } else {
     sr.stop();
   }
 }