Uploaded image for project: 'Application Server 3  4  5 and 6'
  1. Application Server 3 4 5 and 6
  2. JBAS-8655

Caches in session-based tests not correctly initialised (e.g. org.jboss.test.cluster.defaultcfg.simpleweb.test.SessionBasedMaxUnreplicatedInterval)

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • No Release
    • 6.0.0.M4
    • Integration
    • None
    • Low

    Description

      Here is what happens when we execute org.jboss.test.cluster.defaultcfg.simpleweb.test.SessionBasedMaxUnreplicatedInterval:

      CacheConfigTestSetup, a wrapper for the test case, sets up two Infinispan caches by calling SessionTestUtil.createCacheContainer. Before these calls, Brian used JGroupsSystemPropertySupport to temporarily set jgroups.bind_addr, jgroups.udp.mcast_addr and jgroups.udp.mcast_port to values associated with the testsuite's jbosstest.cluster.node1 system property and jbosstest.udpGroup property. He restores the original values after the caches have been created.

      (ii) once the test starts, it calls SessionTestUtil.createManager() to create two instances of org.jboss.web.tomcat.service.session.JBossCacheManager, the session managers used in clustering. These are passed the cahces which were created earlier. The calls to createManager are not preceeded and followed by calls to JGroupsSystemPropertySupport.

      The tests then run.

      The bug is that the caches are not actually started when CacheConfigTestSetup is called, but they are started when SessionTestUtil.createManager is called. So the correct system properties are not getting picked up. I'm guessing that this is a change from JBC behaviour. If I preceed the calls to createManager with JGroupsSystemPropertySupport calls, the caches get intilaised correctly and the tests pass on QA lab hosts which they did not previously. Looking at the logs, I can see the correct addresses. I can't explain why the test passed on my machine and not on the QA lab machines.

      Attachments

        Issue Links

          Activity

            People

              smcgowan@redhat.com Shelly McGowan (Inactive)
              rachmato@redhat.com Richard Achmatowicz
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: