Uploaded image for project: 'DeltaSpike'
  1. DeltaSpike
  2. DELTASPIKE-1198

BeanManagerProvider.isActive() returns true after container shutdown

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.7.0, 1.7.2
    • 1.9.0
    • Core
    • None

    Description

      While trying to implement DELTASPIKE-1197 I found that BeanManagerProvider.isActive() returns true after container shutdown.

      The javadocs for isActive() say "@return true if the BeanManagerProvider is ready to be used", but when it is in this state, the BeanManagerProvider can't actually be used because the CDI container is not active.

      In the case of Weld, when BeanProvider.getContextualReference() was called I got errors like "java.lang.IllegalStateException: Singleton not set for STATIC_INSTANCE => []". There was no stack trace, but that message comes from Weld's RegistrySingletonProvider.java.

      It would seem reasonable to reset bmpSingleton to null during cleanupStoredBeanManagerOnShutdown, but for some reason this breaks a lot of tests.

      Attachments

        Issue Links

          Activity

            People

              struberg Mark Struberg
              sflanigan Sean Flanigan
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: