code: public void update(String serverId) throws AtlasBaseException {
          try {
              CuratorFramework client = curatorFactory.clientInstance();
              HAConfiguration.ZookeeperProperties zookeeperProperties =
                      HAConfiguration.getZookeeperProperties(configuration);
              String atlasServerAddress = HAConfiguration.getBoundAddressForId(configuration, serverId);
              List<ACL> acls = Arrays.asList(
                      new ACL[]{AtlasZookeeperSecurityProperties.parseAcl(zookeeperProperties.getAcl(),
                              ZooDefs.Ids.OPEN_ACL_UNSAFE.get(0))});
              Stat serverInfo = client.checkExists().forPath(getZnodePath(zookeeperProperties));
              if (serverInfo == null) {
                  client.create().
                          withMode(CreateMode.EPHEMERAL).
                          withACL(acls).
                          forPath(getZnodePath(zookeeperProperties));
              }
              client.setData().forPath(getZnodePath(zookeeperProperties),
                      atlasServerAddress.getBytes(Charset.forName("UTF-8")));
          } catch (Exception e) {
              throw new AtlasBaseException(AtlasErrorCode.CURATOR_FRAMEWORK_UPDATE, e, "forPath: getZnodePath");
          }
      }
docs: Update state of the active server instance.
  
  This method writes this instance's Server Address to a shared node in Zookeeper.
  This information is used by other passive instances to locate the current active server.
  @throws Exception
  @param serverId ID of this server instance