glassfish
  1. glassfish
  2. GLASSFISH-17621

ServletContextListener.contextInitialized is called twice in WebContainer.addContext

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.2
    • Fix Version/s: 3.1.2_b09
    • Component/s: embedded
    • Labels:
      None

      Description

      ServletContextListener contextInitialized is called twice when WebContainer.addContext is used.

      During the first contextInitialized method call, the classpath is not correct when using a custom classloader.

      This is due to the fact that the domain.xml is updated when the application is enabled. When the enable attribute config changes in the domain.xml, it will check if the application is already loaded and load the application using the default custom classloader.

        Activity

        Hide
        Amy Roh added a comment -

        Simply changing the order of enable and load fixes the issue.

        Show
        Amy Roh added a comment - Simply changing the order of enable and load fixes the issue.
        Hide
        Amy Roh added a comment -

        Fixed in 50650 & 50651.

        Show
        Amy Roh added a comment - Fixed in 50650 & 50651.

          People

          • Assignee:
            Amy Roh
            Reporter:
            Amy Roh
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: