code: private boolean readAndUpdateVersion(CurrentInProgressMetadataWritable target)
        throws IOException {
      Stat stat = new Stat();
      try {
        byte[] data = zooKeeper.getData(fullyQualifiedZNode, false, stat);
        expectedZNodeVersion.set(stat.getVersion());
        if (data != null) {
          WritableUtil.readWritableFromByteArray(data, target);
          return true;
        }
      } catch (KeeperException e) {
        keeperException("Unrecoverable ZooKeeper error reading from " +
            fullyQualifiedZNode, e);
      } catch (InterruptedException e) {
        interruptedException("Interrupted reading from " + fullyQualifiedZNode,
            e);
      }
      return false;
    }
docs: Reads the ZNode specified in constructor into an existing
  {@link CurrentInProgressMetadataWritable} instance and sets expected
  ZNode version (for next update) the the current version of the
  specified ZNode
  @param target The writable instance to read into
  @return True if there is a log segment is current in-progress, false
  otherwise
  @throws IOException If there is an unrecoverable error talking to
  ZooKeeper