<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Hbase REST API, Globbing Rows undocumented behaviour in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hbase-REST-API-Globbing-Rows-undocumented-behaviour/m-p/55287#M62061</link>
    <description>&lt;P&gt;Hi,&lt;BR /&gt;In our cluster (CM 5.8.4 parcel 5.8.4-1.cdh5.8.4.p0.5, HBase 1.2.0-cdh5.8.4) we would like to retrive rows from Hbase in the simpliest available way using a REST API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To retrive multiple rows with a REST call (GET) we can use the "Globbing Rows" REST api documented here -&amp;gt; &lt;A href="https://hbase.apache.org/1.2/book.html#_rest" target="_blank"&gt;https://hbase.apache.org/1.2/book.html#_rest&lt;/A&gt; in this way:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;A href="http://hbase_url:hbase_port/namespace:table/keywithwildcard*/" target="_blank"&gt;http://hbase_url:hbase_port/namespace:table/keywithwildcard*/&lt;/A&gt;[...]&lt;BR /&gt;(example from documentation: &lt;A href="http://example.com:8000/urls/https|ad.doubleclick.net|*" target="_blank"&gt;http://example.com:8000/urls/https|ad.doubleclick.net|*&lt;/A&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We discovered that there is an undocumented behaviour. We can call the globbing REST api using startrow,endrow parameter in this way:&lt;BR /&gt;&lt;A href="http://hbase_url:hbase_port/namespace:table/startrow,endorow/" target="_blank"&gt;http://hbase_url:hbase_port/namespace:table/startrow,endorow/&lt;/A&gt;[...]&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;In this case it works exaclty as a scan (and it breaks the rest server if you try to retreive too many rows).&lt;/P&gt;&lt;P&gt;We also searched in this hbase souce code mirror (&lt;A href="https://github.com/apache/hbase/blob/master/hbase-rest/src/main/java/org/apache/hadoop/hbase/rest/RowSpec.java" target="_blank"&gt;https://github.com/apache/hbase/blob/master/hbase-rest/src/main/java/org/apache/hadoop/hbase/rest/RowSpec.java&lt;/A&gt;) and noticed that the code is intended to work like this (function private int parseRowKeys(final String path, int i) line 65-110).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Why is this behaviour not documented?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it safe to use (with restriction) this REST call instead of use a scanner or the absence of documentation means that the function will change without any comunication (not even the "deprecated" stuff)?&lt;/P&gt;</description>
    <pubDate>Fri, 16 Sep 2022 11:40:52 GMT</pubDate>
    <dc:creator>seleoni</dc:creator>
    <dc:date>2022-09-16T11:40:52Z</dc:date>
    <item>
      <title>Hbase REST API, Globbing Rows undocumented behaviour</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hbase-REST-API-Globbing-Rows-undocumented-behaviour/m-p/55287#M62061</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;In our cluster (CM 5.8.4 parcel 5.8.4-1.cdh5.8.4.p0.5, HBase 1.2.0-cdh5.8.4) we would like to retrive rows from Hbase in the simpliest available way using a REST API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To retrive multiple rows with a REST call (GET) we can use the "Globbing Rows" REST api documented here -&amp;gt; &lt;A href="https://hbase.apache.org/1.2/book.html#_rest" target="_blank"&gt;https://hbase.apache.org/1.2/book.html#_rest&lt;/A&gt; in this way:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;A href="http://hbase_url:hbase_port/namespace:table/keywithwildcard*/" target="_blank"&gt;http://hbase_url:hbase_port/namespace:table/keywithwildcard*/&lt;/A&gt;[...]&lt;BR /&gt;(example from documentation: &lt;A href="http://example.com:8000/urls/https|ad.doubleclick.net|*" target="_blank"&gt;http://example.com:8000/urls/https|ad.doubleclick.net|*&lt;/A&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We discovered that there is an undocumented behaviour. We can call the globbing REST api using startrow,endrow parameter in this way:&lt;BR /&gt;&lt;A href="http://hbase_url:hbase_port/namespace:table/startrow,endorow/" target="_blank"&gt;http://hbase_url:hbase_port/namespace:table/startrow,endorow/&lt;/A&gt;[...]&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;In this case it works exaclty as a scan (and it breaks the rest server if you try to retreive too many rows).&lt;/P&gt;&lt;P&gt;We also searched in this hbase souce code mirror (&lt;A href="https://github.com/apache/hbase/blob/master/hbase-rest/src/main/java/org/apache/hadoop/hbase/rest/RowSpec.java" target="_blank"&gt;https://github.com/apache/hbase/blob/master/hbase-rest/src/main/java/org/apache/hadoop/hbase/rest/RowSpec.java&lt;/A&gt;) and noticed that the code is intended to work like this (function private int parseRowKeys(final String path, int i) line 65-110).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Why is this behaviour not documented?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it safe to use (with restriction) this REST call instead of use a scanner or the absence of documentation means that the function will change without any comunication (not even the "deprecated" stuff)?&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 11:40:52 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hbase-REST-API-Globbing-Rows-undocumented-behaviour/m-p/55287#M62061</guid>
      <dc:creator>seleoni</dc:creator>
      <dc:date>2022-09-16T11:40:52Z</dc:date>
    </item>
    <item>
      <title>Re: Hbase REST API, Globbing Rows undocumented behaviour</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hbase-REST-API-Globbing-Rows-undocumented-behaviour/m-p/56546#M62062</link>
      <description>&lt;P&gt;&lt;SPAN&gt;We engaged vendor professional support and we discovered that:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;​1- There is an internal thread on&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;HBase REST API documentation that needs enhancement&lt;BR /&gt;​2- It is possible to use this endpoint (but is not safe if you not have the control of the client that call the service) and, because it can cause OOM, is better/mandatory to use kerberos auth for Hbase REST API&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Jun 2017 08:54:18 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Hbase-REST-API-Globbing-Rows-undocumented-behaviour/m-p/56546#M62062</guid>
      <dc:creator>seleoni</dc:creator>
      <dc:date>2017-06-27T08:54:18Z</dc:date>
    </item>
  </channel>
</rss>

