3 Replies Latest reply on Jul 6, 2009 10:05 AM by Clebert Suconic

    DuplicateDetectionTest::testNoPersistXA1 fails if libaio is

    Jeff Mesnil Master

      The test DuplicateDetectionTest::testNoPersistXA1 passes when libaio is installed on the OS but fails when it is not installed.

      I observed the failure on mac os x.
      Then I ran the tests on Linux. it passes when I installed libaio but when I remove the lib it fails with the error:

      [main] 11:00:39,077 INFO [org.jboss.messaging.tests.util.UnitTestCase] ###### starting test org.jboss.messaging.tests.integration.DuplicateDetectionTest.testNoPersistXA1
      [main] 11:00:39,413 WARNING [org.jboss.messaging.core.management.impl.ManagementServiceImpl] It has been detected that the cluster admin user and password which are used to replicate management operation from one node to the other have not been changed from the installation default. Please see the JBoss Messaging user guide for instructions on how to do this.
      [main] 11:00:39,626 INFO [org.jboss.messaging.core.server.impl.MessagingServerImpl] JBoss Messaging Server version 2.0.0.BETA3 (maggot, 104) started
      [main] 11:00:39,629 INFO [org.jboss.messaging.core.server.impl.MessagingServerImpl] JBoss Messaging Server version 2.0.0.BETA3 (maggot, 104) stopped
      [main] 11:00:39,637 WARNING [org.jboss.messaging.core.management.impl.ManagementServiceImpl] It has been detected that the cluster admin user and password which are used to replicate management operation from one node to the other have not been changed from the installation default. Please see the JBoss Messaging user guide for instructions on how to do this.
      [main] 11:00:39,680 INFO [org.jboss.messaging.core.persistence.impl.journal.JournalStorageManager] AIO journal selected
      [main] 11:00:39,687 WARNING [org.jboss.messaging.core.persistence.impl.journal.JournalStorageManager] AIO wasn't located on this platform, it will fall back to using pure Java NIO. If your platform is Linux, install LibAIO to enable the AIO journal
      [main] 11:00:39,918 INFO [org.jboss.messaging.core.server.impl.MessagingServerImpl] JBoss Messaging Server version 2.0.0.BETA3 (maggot, 104) started
      [Thread-1 (group:JBM-server-threads15310053-3907502)] 11:00:40,127 SEVERE [org.jboss.messaging.core.server.impl.ServerSessionImpl] Failed to xa prepare
      java.lang.NullPointerException
       at org.jboss.messaging.core.journal.impl.JournalTransaction.syncPreviousFiles(JournalTransaction.java:224)
       at org.jboss.messaging.core.journal.impl.JournalImpl.appendPrepareRecord(JournalImpl.java:1171)
       at org.jboss.messaging.core.persistence.impl.journal.JournalStorageManager.prepare(JournalStorageManager.java:411)
       at org.jboss.messaging.core.transaction.impl.TransactionImpl.prepare(TransactionImpl.java:166)
       at org.jboss.messaging.core.server.impl.ServerSessionImpl.doHandleXAPrepare(ServerSessionImpl.java:2160)
       at org.jboss.messaging.core.server.impl.ServerSessionImpl.handleXAPrepare(ServerSessionImpl.java:702)
       at org.jboss.messaging.core.server.impl.ServerSessionPacketHandler.handlePacket(ServerSessionPacketHandler.java:215)
       at org.jboss.messaging.core.remoting.impl.ChannelImpl.handlePacket(ChannelImpl.java:621)
       at org.jboss.messaging.core.remoting.impl.RemotingConnectionImpl.bufferReceived(RemotingConnectionImpl.java:399)
       at org.jboss.messaging.core.remoting.server.impl.RemotingServiceImpl$DelegatingBufferHandler.bufferReceived(RemotingServiceImpl.java:483)
       at org.jboss.messaging.core.remoting.impl.invm.InVMConnection$1.run(InVMConnection.java:136)
       at org.jboss.messaging.utils.OrderedExecutorFactory$OrderedExecutor$1.run(OrderedExecutorFactory.java:105)
       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:651)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:676)
       at java.lang.Thread.run(Thread.java:613)
      


      This is the only test in the class which fails if libaio is not installed. All the other tests pass where the lib is there or not.

      Does someone see a relation between this test and the libaio installation?

        • 1. Re: DuplicateDetectionTest::testNoPersistXA1 fails if libaio
          Jeff Mesnil Master

          same behavior on BasicXARecoveryTest::testNonPersistent & testNonPersistentMultipleIDs
          The XAException is caused by the same NPE.

          All the tests in XALargeMessageMultiThreadFailoverTest fails too when libaio is not installed:

          java.lang.Exception: Exception on thread Thread[Thread-5,5,]
           at org.jboss.messaging.tests.integration.cluster.failover.MultiThreadFailoverSupport.runMultipleThreadsFailoverTest(MultiThreadFailoverSupport.java:169)
           at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.runTestMultipleThreads(XAMultiThreadRandomFailoverTest.java:670)
           at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.testC(XAMultiThreadRandomFailoverTest.java:107)
          Caused by: javax.transaction.xa.XAException
           at org.jboss.messaging.core.client.impl.ClientSessionImpl.commit(ClientSessionImpl.java:820)
           at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.transactionallySendMessages(XAMultiThreadRandomFailoverTest.java:544)
           at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.doTestC(XAMultiThreadRandomFailoverTest.java:186)
           at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest$1.run(XAMultiThreadRandomFailoverTest.java:112)
           at org.jboss.messaging.tests.integration.cluster.failover.MultiThreadFailoverSupport$1Runner.run(MultiThreadFailoverSupport.java:135)
          


          • 2. Re: DuplicateDetectionTest::testNoPersistXA1 fails if libaio
            Jeff Mesnil Master

            I did a whole run on Linux w/o libaio and the following tests fail:

            JMSTest
            - test_Asynchronous_to_Client
            DuplicateDetectionTest
            - testNoPersistXA1
            LargeMessageTest
            - testFilePersistenceBlockedPreACKXA
            - testFilePersistenceBlockedPreACKXAConsumer
            - testSendRollbackXA
            - testSimpleRollbackXA
            XALargeMessageMultiThreadFailoverTest
            - testC
            - testD
            - testG
            - testH
            ScheduledMessageTest
            - testScheduledDeliveryTX
            LVQRecoveryTest
            - testManyMessagesReceivedWithRollback
            BasicXaRecoveryTest
            - testNonPersistent
            - testNonPersistentMultipleIDs

            I did not count the AIO integration tests which are expected to fail in that case

            • 3. Re: DuplicateDetectionTest::testNoPersistXA1 fails if libaio
              Clebert Suconic Master

              Thanks Jeff, Nice catch.

              It should be fixed now.