hbase-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "stack (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HBASE-1107) NPE in HStoreScanner.updateReaders
Date Sat, 14 Mar 2009 18:32:50 GMT

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

stack commented on HBASE-1107:
------------------------------

The code in updateReaders was changed significantly for 0.19.1 (We don't open readers we already
had open).

The NPE above as Andrew has already pointed out comes from here:

{code}
          // I think its safe getting key from mem at this stage -- it shouldn't have
          // been flushed yet
          this.scanners[HSFS_INDEX] = new StoreFileScanner(this.store,
              this.timestamp, this. targetCols, this.keys[MEMS_INDEX].getRow());
{code}

It looks like its the this.keys[MEMS_INDEX] is null.

In testing while doing the 0.19.1 changes I was able to make this NPE.   It happened when
updateReaders was called after the both memory and the file scanners had been exhausted but
the scanner had not yet been closed down fully.  The attempt to get from the memory key was
failing because it had been set to null after its last next.

Now, we keep the last next key and use that instead of trying to go to memcache (thinking
on it, memcache exhaustion can always happen ahead of store file scanner exhaustion).

> NPE in HStoreScanner.updateReaders
> ----------------------------------
>
>                 Key: HBASE-1107
>                 URL: https://issues.apache.org/jira/browse/HBASE-1107
>             Project: Hadoop HBase
>          Issue Type: Bug
>    Affects Versions: 0.19.1, 0.20.0
>            Reporter: Andrew Purtell
>            Assignee: Andrew Purtell
>            Priority: Blocker
>         Attachments: 1107-1.patch
>
>
> 2009-01-01 23:55:41,629 FATAL org.apache.hadoop.hbase.regionserver.MemcacheFlusher: Replay
of hlog required. Forcing server shutdown
> org.apache.hadoop.hbase.DroppedSnapshotException: region: content,cff13605e2ea6ce0b221ac864687bf08,1230777531253
>         at org.apache.hadoop.hbase.regionserver.HRegion.internalFlushcache(HRegion.java:880)
>         at org.apache.hadoop.hbase.regionserver.HRegion.flushcache(HRegion.java:773)
>         at org.apache.hadoop.hbase.regionserver.MemcacheFlusher.flushRegion(MemcacheFlusher.java:227)
>         at org.apache.hadoop.hbase.regionserver.MemcacheFlusher.run(MemcacheFlusher.java:137)
> Caused by: java.lang.NullPointerException
>         at org.apache.hadoop.hbase.regionserver.HStoreScanner.updateReaders(HStoreScanner.java:322)
>         at org.apache.hadoop.hbase.regionserver.HStore.notifyChangedReadersObservers(HStore.java:737)
>         at org.apache.hadoop.hbase.regionserver.HStore.updateReaders(HStore.java:725)
>         at org.apache.hadoop.hbase.regionserver.HStore.internalFlushCache(HStore.java:694)
>         at org.apache.hadoop.hbase.regionserver.HStore.flushCache(HStore.java:630)
>         at org.apache.hadoop.hbase.regionserver.HRegion.internalFlushcache(HRegion.java:865)
>         ... 3 more

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message