Hi all,

we are in the process of upgrading HBase from 0.92.x to 0.98.6.x and run
into this code in the HBase-client:
  /**
   * {@inheritDoc}
   */
  @Override
  public boolean exists(final Get get) throws IOException {
    get.setCheckExistenceOnly(true);
    Result r = get(get);
    assert r.getExists() != null;
    return r.getExists();
  }

We used to use this exists-call as this was way faster in case of a
BloomFilter-miss. But maybe that has changed?

The code shows that the get-object passed-in is changed. Now I understand
that it might not make sense to re-use the get-object after the exists
returns true, but I explained the reason for doing so anyway above.

Can anyone throw some light on this, please?

I was just wondering if it might make sense to add a notice in the API-doc
that tell that the passed-in object will be changed during the call. Or
maybe add a 'set-back-to-old-value' try-finally-construction.

with kind regards,
Gerke

Reply via email to