hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Appy (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-18961) doMiniBatchMutate() is big, split it into smaller methods
Date Wed, 11 Oct 2017 23:35:00 GMT

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

Appy commented on HBASE-18961:
------------------------------

Posting improvement suggestions from HBASE-18960 here since we don't want to block that and
keep things moving:
- This is used so often. Probably add a function {{batchOp.isOperationPending(i)}} for it.
{noformat}
if (batchOp.retCodeDetails[lastIndexExclusive].getOperationStatusCode() != OperationStatusCode.NOT_RUN)
{
{noformat}
- "writeEntry" only seems to be used for non-reply case. Can we rename it to make it explicit?
And return null from doWALAppend when it's replay mode?
- In all earlier cases of doWALAppend(), WALEdit was checked to be non-empty. Make keep that
invariant (and even add precondition check for it in the function). Seeing {{if (walEdit.isEmpty()}}
in the function, it made me search everywhere what if it was empty.
- move writeRequestsCount to doMiniBatchMutation. Right now, if the operation actually fails
with exception, we are still incrementing that counter.
- In batchMutate(), can we move initialization section out of while(isDone()) loop.

> doMiniBatchMutate() is big, split it into smaller methods
> ---------------------------------------------------------
>
>                 Key: HBASE-18961
>                 URL: https://issues.apache.org/jira/browse/HBASE-18961
>             Project: HBase
>          Issue Type: Sub-task
>          Components: regionserver
>    Affects Versions: 2.0.0-alpha-3
>            Reporter: Umesh Agashe
>            Assignee: Umesh Agashe
>             Fix For: 2.0.0-alpha-4
>
>
> Split doMiniBatchMutate() and improve readability.



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

Mime
View raw message