[ 
https://issues.apache.org/jira/browse/HBASE-13333?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16159867#comment-16159867
 ] 

Chia-Ping Tsai commented on HBASE-13333:
----------------------------------------

bq. that is hella confusing but I guess correct then
The codes you posted is not committed to branch-1 but master.
{code}
diff --git 
a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ResultScanner.java 
b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ResultScanner.java
index 381505c..6b7f1dd 100644
--- 
a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ResultScanner.java
+++ 
b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ResultScanner.java
@@ -52,4 +52,10 @@ public interface ResultScanner extends Closeable, 
Iterable<Result> {
    */
   @Override
   void close();
+
+  /**
+   * Allow the client to renew the scanner's lease on the server.
+   * @return true if the lease was successfully renewed, false otherwise.
+   */
+  boolean renewLease();
 }
{code}

> Renew Scanner Lease without advancing the RegionScanner
> -------------------------------------------------------
>
>                 Key: HBASE-13333
>                 URL: https://issues.apache.org/jira/browse/HBASE-13333
>             Project: HBase
>          Issue Type: Bug
>            Reporter: Lars Hofhansl
>            Assignee: Lars Hofhansl
>             Fix For: 2.0.0, 0.98.13, 1.0.2, 1.2.0, 1.1.1
>
>         Attachments: 13333-0.98.txt, 13333-master.txt
>
>
> We have a usecase (for Phoenix) where we want to let the server know that the 
> client is still around. Like a client-side heartbeat.
> Doing a full heartbeat is complicated, but we could add the ability to make 
> scanner call with caching set to 0. The server already does the right thing 
> (it renews the lease, but does not advance the scanner).
> It looks like the client (ScannerCallable) also does the right thing. We 
> cannot break ResultScanner before HBase 2.0, but we can add a renewLease() 
> method to AbstractClientScaner. Phoenix (or any other caller) can then cast 
> to ClientScanner and call that method to ensure we renew the lease on the 
> server.
> It would be a simple and fully backwards compatible change. [~giacomotaylor]
> Comments?



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to