private int lookupValue(@NotNull Int2IntMultimap valueHashToId,
                          @NotNull String value,
                          int hash) throws IOException {
    IntRef foundIdRef = new IntRef(NULL_ID);
    try {
      valueHashToId.lookup(hash, candidateId -> {
        try {
          String candidateValue = valuesLog.read(candidateId, DurableStringEnumerator::readString);
          if (candidateValue.equals(value)) {
            foundIdRef.set(candidateId);
            return false;//stop
          }
          return true;
        }
        catch (IOException ex) {
          throw new UncheckedIOException(ex);
        }
      });
      return foundIdRef.get();
    }
    catch (UncheckedIOException ex) {
      throw ex.getCause();
    }
  }
private int lookupValue(@NotNull Int2IntMultimap valueHashToId,
                          @NotNull String value,
                          int hash)