Uploaded image for project: 'Phoenix'
  1. Phoenix
  2. PHOENIX-849

Test StatsManagerIT#testStatsManager is flaky

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 3.0.0, 4.0.0
    • None
    • None

    Description

      You will see it fails if you run it 10 times in a loop. Below is the error stack trace:

      java.lang.AssertionError: null
      	at org.junit.Assert.fail(Assert.java:86)
      	at org.junit.Assert.assertTrue(Assert.java:41)
      	at org.junit.Assert.assertTrue(Assert.java:52)
      	at org.apache.phoenix.end2end.StatsManagerTest.testStatsManager(StatsManagerTest.java:136)
      

      The root cause is that the constructor MinKeyChange & MaxKeyChange internally trigger the states update

              MinKeyChange minKeyChange = new MinKeyChange(stats, table);
              MaxKeyChange maxKeyChange = new MaxKeyChange(stats, table);
      

      So the latter

      stats.getMinKey(table);

      gets a different value unexpectedly.

      Attachments

        1. phoenix-849.patch
          0.8 kB
          Jeffrey Zhong

        Activity

          People

            Unassigned Unassigned
            jeffreyz Jeffrey Zhong
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: