[
https://issues.apache.org/jira/browse/HBASE-18233?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16273655#comment-16273655
]
stack commented on HBASE-18233:
-------------------------------
Here is the relevant change section:
{code}
- if(!lockAvailable) {
+ if (!lockAvailable) {
if (traceScope != null) {
traceScope.getSpan().addTimelineAnnotation("Failed to get row lock");
}
result = null;
- String message = "Timed out waiting for lock for row: " + rowKey + "
in region "
- + getRegionInfo().getEncodedName();
- if (reachDeadlineFirst) {
- throw new TimeoutIOException(message);
- } else {
- if(waitForLock) {
+ String message = "Timed out waiting for lock for row: " + rowKey + "
in region " +
+ getRegionInfo().getEncodedName() + ", timeout=" + timeout + ",
deadlined=" +
+ reachDeadlineFirst + ", waitForLock=" + waitForLock;
+ if (waitForLock) {
+ if (reachDeadlineFirst) {
+ LOG.info("TIMEOUT: " + message);
+ throw new TimeoutIOException(message);
+ } else {
// If timeToDeadline is larger than rowLockWaitDuration, we can
not drop the request.
+ LOG.info("IOE " + message);
throw new IOException(message);
- } else {
- return null;
}
+ } else {
+ // We are here if we did a tryLock w/o waiting on it.
+ return null;
}
{code}
I was doing a test of reachDeadlineFirst and then whether I was to waitForLock
when should have been flipped.
> We shouldn't wait for readlock in doMiniBatchMutation in case of deadlock
> -------------------------------------------------------------------------
>
> Key: HBASE-18233
> URL: https://issues.apache.org/jira/browse/HBASE-18233
> Project: HBase
> Issue Type: Bug
> Affects Versions: 1.2.7
> Reporter: Allan Yang
> Assignee: Allan Yang
> Priority: Blocker
> Fix For: 1.3.2, 1.4.1, 1.2.7
>
> Attachments: HBASE-18233-branch-1.2.patch,
> HBASE-18233-branch-1.2.trivial.patch, HBASE-18233-branch-1.2.v2.patch,
> HBASE-18233-branch-1.2.v3.patch, HBASE-18233-branch-1.2.v4 (1).patch,
> HBASE-18233-branch-1.2.v4 (1).patch, HBASE-18233-branch-1.2.v4 (2).patch,
> HBASE-18233-branch-1.2.v4.patch, HBASE-18233-branch-1.2.v4.patch,
> HBASE-18233-branch-1.2.v4.patch, HBASE-18233-branch-1.2.v4.patch,
> HBASE-18233-branch-1.2.v4.patch, HBASE-18233-branch-1.2.v4.patch,
> HBASE-18233-branch-1.2.v4.patch, HBASE-18233-branch-1.2.v4.patch,
> HBASE-18233-branch-1.2.v5 (1).patch, HBASE-18233-branch-1.2.v5.patch,
> HBASE-18233-branch-1.2.v5.patch, HBASE-18233-branch-1.2.v6.patch,
> HBASE-18233.branch-1.2.UT.log, HBASE-18233.branch-1.3.001.patch,
> HBASE-18233.branch-1.3.001.patch, HBASE-18233.branch-1.3.002.patch,
> HBASE-18233.branch-1.3.002.patch, HBASE-18233.branch-1.3.003.patch,
> HBASE-18233.branch-1.3.003.patch, HBASE-18233.branch-1.4.001.patch,
> HBASE-18233.branch-1.4.002.patch, HBASE-18233.branch-1.4.002.patch
>
>
> Please refer to the discuss in HBASE-18144
> https://issues.apache.org/jira/browse/HBASE-18144?focusedCommentId=16051701&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-16051701
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)