Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-12074

TestLogRollingNoCluster#testContendedLogRolling() failed

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • None
    • None
    • None
    • None

    Description

      TestLogRollingNoCluster#testContendedLogRolling() failed on a 0.98 run. I am trying to understand the context.

      The failure is this:

      java.lang.AssertionError
      	at org.junit.Assert.fail(Assert.java:86)
      	at org.junit.Assert.assertTrue(Assert.java:41)
      	at org.junit.Assert.assertFalse(Assert.java:64)
      	at org.junit.Assert.assertFalse(Assert.java:74)
      	at org.apache.hadoop.hbase.regionserver.wal.TestLogRollingNoCluster.testContendedLogRolling(TestLogRollingNoCluster.java:80)
      

      Caused because one of the Appenders calling FSHLog.sync() threw IOE because of concurrent close:

      4-09-23 16:36:39,530 FATAL [pool-1-thread-1-WAL.AsyncSyncer0] wal.FSHLog$AsyncSyncer(1246): Error while AsyncSyncer sync, request close of hlog 
      java.io.IOException: java.lang.NullPointerException
      	at org.apache.hadoop.hbase.regionserver.wal.ProtobufLogWriter.sync(ProtobufLogWriter.java:168)
      	at org.apache.hadoop.hbase.regionserver.wal.FSHLog$AsyncSyncer.run(FSHLog.java:1241)
      	at java.lang.Thread.run(Thread.java:722)
      Caused by: java.lang.NullPointerException
      	at org.apache.hadoop.hbase.regionserver.wal.ProtobufLogWriter.sync(ProtobufLogWriter.java:165)
      	... 2 more
      2014-09-23 16:36:39,531 INFO  [32] wal.TestLogRollingNoCluster$Appender(137): Caught exception from Appender:32
      java.io.IOException: java.lang.NullPointerException
      	at org.apache.hadoop.hbase.regionserver.wal.ProtobufLogWriter.sync(ProtobufLogWriter.java:168)
      	at org.apache.hadoop.hbase.regionserver.wal.FSHLog$AsyncSyncer.run(FSHLog.java:1241)
      	at java.lang.Thread.run(Thread.java:722)
      Caused by: java.lang.NullPointerException
      	at org.apache.hadoop.hbase.regionserver.wal.ProtobufLogWriter.sync(ProtobufLogWriter.java:165)
      	... 2 more
      2014-09-23 16:36:39,532 INFO  [19] wal.TestLogRollingNoCluster$Appender(137): Caught exception from Appender:19
      java.io.IOException: java.lang.NullPointerException
      	at org.apache.hadoop.hbase.regionserver.wal.ProtobufLogWriter.sync(ProtobufLogWriter.java:168)
      	at org.apache.hadoop.hbase.regionserver.wal.FSHLog$AsyncSyncer.run(FSHLog.java:1241)
      	at java.lang.Thread.run(Thread.java:722)
      Caused by: java.lang.NullPointerException
      	at org.apache.hadoop.hbase.regionserver.wal.ProtobufLogWriter.sync(ProtobufLogWriter.java:165)
      	... 2 more
      

      The code is:

        public void sync() throws IOException {
          try {
            this.output.flush();
            this.output.sync();
          } catch (NullPointerException npe) {
            // Concurrent close...
            throw new IOException(npe);
          }
        }
      

      I think the test case written exactly to catch this case:

         * Spin up a bunch of threads and have them all append to a WAL.  Roll the
         * WAL frequently to try and trigger NPE.
      

      This is why I am reporting since I don't have much context. It may not be a test issue, but an actual bug.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              enis Enis Soztutar
              Votes:
              1 Vote for this issue
              Watchers:
              11 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: