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

Phil Yang commented on HBASE-17210:
-----------------------------------

Before this patch, if a Call with 1000ms timeout being blocked by getting a row 
lock, the request will be regarded as timeout at client but the handler will 
not be released until it gets the lock and do the work. In the worst case the 
handler will be occupied for 30s because the default timeout for getting row 
lock is 30s.
After this patch, if a Call's timeout is 1000ms, the timeout of tryLock will 
also be 1000ms. If timeout, we will throw a TimeoutIOException and the handler 
will be released.

bq. Asking because seeing something where all handlers are blocked trying to 
get a lock but weirdly no handler seems to have the lock; i.e. no one is doing 
work.

The lock is not released correctly? In this patch we only throw exception when 
tryLock return false which means the lock is not acquired.

> Set timeout on trying rowlock according to client's RPC timeout
> ---------------------------------------------------------------
>
>                 Key: HBASE-17210
>                 URL: https://issues.apache.org/jira/browse/HBASE-17210
>             Project: HBase
>          Issue Type: Sub-task
>            Reporter: Phil Yang
>            Assignee: Phil Yang
>             Fix For: 2.0.0, 1.4.0
>
>         Attachments: HBASE-17120.v1.patch, HBASE-17210.branch-1.v01.patch, 
> HBASE-17210.branch-1.v02.patch, HBASE-17210.branch-1.v03.patch, 
> HBASE-17210.v02.patch, HBASE-17210.v03.patch, HBASE-17210.v04.patch, 
> HBASE-17210.v04.patch
>
>
> Now when we want to get a row lock, the timeout is fixed and default is 30s. 
> But the requests from client have different RPC timeout setting. We can use 
> the client's deadline to set timeout on tryLock.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to