Search code examples
javahbase

multiple or bulk fetch or get in HBase Java client?


Does the HBase Java client support multi-get (aka bulk fetch), kind of like memcached multi-get? I've scoured the docs and the Internet for at least an hour and couldn't find anything definitive. The HTable API offers multiple Delete and multiple Put, but does not have any obvious analogous call for Get.

To clarify, I am trying to Get disparate records, not a sequence of records. So Scan isn't what I would intuitively use.

I did read something on a thread (maybe on JIRA) about Scan offering equivalent functionality for batch random access using filters. If someone can confirm that this is the best practice, and maybe point me at the right type of Filter to use, then I'll go that route.

Thanks!


Solution

  • It is already supported as of HBase 0.90 (https://issues.apache.org/jira/browse/HBASE-1845). However, some HBase client does not support that yet (https://github.com/OpenTSDB/asynchbase/issues/54)