Uploaded image for project: 'ActiveMQ Artemis'
  1. ActiveMQ Artemis
  2. ARTEMIS-3654

AllClassesTest can create and fail to close a LibaioContext instance

    XMLWordPrintableJSON

Details

    • Test
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.20.0
    • 2.21.0
    • Tests
    • None

    Description

      AllClassesTest tries to create objects with random args as part of its check. It never closes these.

      A cascading test failure was noticed due to the static TotalMaxIO check done before/after ActiveMQTestBase based tests to check for AIO context leaks. As AllClassesTest was the only test to run in the JVM before this happened, it essentially had to be the cause.

      The behaviour would fit with it generally failing to create the LibaioContext instance due to its internal checks, but succeeding this one time, then not closing it.

       [INFO] -------------------------------------------------------
      [INFO]  T E S T S
      [INFO] -------------------------------------------------------
      [INFO] Running org.apache.activemq.artemis.tests.unit.AllClassesTest
      SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
      SLF4J: Defaulting to no-operation (NOP) logger implementation
      SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
      Warning:  Tests run: 1362, Failures: 0, Errors: 0, Skipped: 280, Time elapsed: 3.551 s - in org.apache.activemq.artemis.tests.unit.AllClassesTest
      [INFO] Running org.apache.activemq.artemis.tests.unit.core.asyncio.MultiThreadAsynchronousFileTest
      [main] 11:27:22,623 ERROR [org.apache.activemq.artemis.tests.util.ActiveMQTestBase] LibaioContext TotalMaxIO > 0 before beginning test class. Issue presumably arose in a preceding class (not possible to be sure of which here). TotalMaxIO = 39416
      [main] 11:27:52,682 ERROR [org.apache.activemq.artemis.tests.util.ActiveMQTestBase] LibaioContext TotalMaxIO > 0 leak detected after class not-yet-set(), TotalMaxIO=39416(). Check output to determine if occurred before/during.
      Error:  Tests run: 2, Failures: 1, Errors: 1, Skipped: 0, Time elapsed: 30.022 s <<< FAILURE! - in org.apache.activemq.artemis.tests.unit.core.asyncio.MultiThreadAsynchronousFileTest
      Error:  org.apache.activemq.artemis.tests.unit.core.asyncio.MultiThreadAsynchronousFileTest  Time elapsed: 30.022 s  <<< ERROR!
      org.junit.TestCouldNotBeSkippedException: Test could not be skipped due to other failures
      	at org.apache.activemq.artemis.tests.unit.core.asyncio.MultiThreadAsynchronousFileTest.hasAIO(MultiThreadAsynchronousFileTest.java:52)
      
      Error:  org.apache.activemq.artemis.tests.unit.core.asyncio.MultiThreadAsynchronousFileTest  Time elapsed: 30.022 s  <<< FAILURE!
      java.lang.AssertionError: LibaioContext TotalMaxIO > 0 leak detected after class not-yet-set(), TotalMaxIO=39416(). Check output to determine if occurred before/during.
      
      [INFO] Running org.apache.activemq.artemis.tests.unit.core.client.impl.LargeMessageBufferTest
      Error:  Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.011 s <<< FAILURE! - in org.apache.activemq.artemis.tests.unit.core.client.impl.LargeMessageBufferTest
      Error:  org.apache.activemq.artemis.tests.unit.core.client.impl.LargeMessageBufferTest  Time elapsed: 0.011 s  <<< FAILURE!
      java.lang.AssertionError: Aborting, LibaioContext TotalMaxIO > 0 issue previously detected by test class not-yet-set(), see its output.
      

      Attachments

        Issue Links

          Activity

            People

              brusdev Domenico Francesco Bruscino
              robbie Robbie Gemmell
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 10m
                  10m