hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eshcar Hillel (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-17407) Correct update of maxFlushedSeqId in HRegion
Date Wed, 04 Jan 2017 08:54:58 GMT

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

Eshcar Hillel commented on HBASE-17407:

Here is what I read:
  void abortCacheFlush(final byte[] encodedRegionName) {
    // Method is called when we are crashing down because failed write flush AND it is called
    // if we fail prepare. The below is for the fail prepare case; we restore the old sequence
Let me rephrase what I said as a question:
Is it possible to execute WAL truncation based on the values in SequenceIdAccounting while
a flush is on going and between startCacheFlush() and completeCacheFlush()?
My guess would be that it cannot happen. Having a startXXX/completeXXX/abortXXX feels much
like a transaction, and therefore some mutual exclusion mechanism should prevent other protocols
accessing resources (like in SequenceIdAccounting) while the transaction access them.

If a WAL truncation may happen in parallel with the flush then you are right and we have a
problem with flushing the tail that needs to be fixed.
However if this is the case *and* the transaction can be aborted due to various reasons (like
failed prepare) then there is an even bigger problem - danger of data loss upon every flush.
I suspect this is not the case.

> Correct update of maxFlushedSeqId in HRegion
> --------------------------------------------
>                 Key: HBASE-17407
>                 URL: https://issues.apache.org/jira/browse/HBASE-17407
>             Project: HBase
>          Issue Type: Bug
>            Reporter: Eshcar Hillel
> The attribute maxFlushedSeqId in HRegion is used to track the max sequence id in the
store files and is reported to HMaster. When flushing only part of the memstore content this
value might be incorrect and may cause data loss.

This message was sent by Atlassian JIRA

View raw message