예제 #1
0
  @Override
  protected void doStart() throws Exception {
    setLeader(tryTakeLeadership());
    watch();

    super.doStart();
  }
예제 #2
0
  @Override
  protected void doStop() throws Exception {
    if (managedClient) {
      client.close();
    }

    super.doStop();
  }