Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-1157

StartupListener overwrites ManagerInstance.instance even if it's set already by container.

    XMLWordPrintable

Details

    Description

      Currently, the REST server looks up the existing EmbeddedCacheManager provided by JBossAS 6 in StartupListener.getMcInjectedCacheManager().

      This unfortunately does not work in JBossAS 7 because it switched to a new controller. To get the provided EmbeddedCacheManager, a .WAR must include a class that implements org.jboss.msc.service.ServiceActivator, and we need to get the cache manager there. Here are some examples:

      http://j.mp/jNX2gr
      http://j.mp/kleOLi

      The good news is that the ServiceActivator is invoked before the web application goes on-line. The bad news is that it is reset to null by StartupListener.getMcInjectedCacheManager().

      The fix to this problem is to modify StartupListener so that it does not update ManagerInstance.instance if set already.

      Attachments

        Activity

          People

            trustin_jira Trustin Lee (Inactive)
            trustin_jira Trustin Lee (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: