protected final void internalStop() {
    if (zkPermissionWatcher != null) {
      zkPermissionWatcher.close();
    }
    rpcServer.stop();
  }
Base class for Master and RegionServer RpcServices.
hbase-server/src/main/java/org/apache/hadoop/hbase/HBaseRpcServicesBase.java