Uploaded image for project: 'OpenWebBeans'
  1. OpenWebBeans
  2. OWB-788

deployment error when a @Specializes bean is disabled via an Extension

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • 1.2.0
    • 1.2.0
    • None

    Description

      When a @Specializes bean gets disabled via a CDI Extension (ProcessAnnotatedType.veto() then we blow up with an Exception

      org.apache.webbeans.exception.WebBeansConfigurationException: org.apache.webbeans.exception.WebBeansDeploymentException: org.apache.webbeans.exception.inject.InconsistentSpecializationException: Specialized bean for class : class org.apache.webbeans.newtests.specalization.disabledspecialization.MockLoginService is not enabled in the deployment.
      at org.apache.webbeans.newtests.AbstractUnitTest.startContainer(AbstractUnitTest.java:130)
      at org.apache.webbeans.newtests.AbstractUnitTest.startContainer(AbstractUnitTest.java:77)
      at org.apache.webbeans.newtests.specalization.disabledspecialization.DisabledSpecializationTest.testSpecialization(DisabledSpecializationTest.java:35)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
      at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
      at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
      at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
      at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
      at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
      at org.junit.runners.BlockJUnit4ClassRunner.runNotIgnored(BlockJUnit4ClassRunner.java:79)
      at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:71)
      at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:49)
      at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193)
      at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52)
      at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191)
      at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42)
      at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184)
      at org.junit.runners.ParentRunner.run(ParentRunner.java:236)
      at org.junit.runner.JUnitCore.run(JUnitCore.java:157)
      at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:63)
      Caused by: org.apache.webbeans.exception.WebBeansDeploymentException: org.apache.webbeans.exception.inject.InconsistentSpecializationException: Specialized bean for class : class org.apache.webbeans.newtests.specalization.disabledspecialization.MockLoginService is not enabled in the deployment.
      at org.apache.webbeans.config.BeansDeployer.checkSpecializations(BeansDeployer.java:704)
      at org.apache.webbeans.config.BeansDeployer.deploy(BeansDeployer.java:191)
      at org.apache.webbeans.lifecycle.AbstractLifeCycle.startApplication(AbstractLifeCycle.java:127)
      at org.apache.webbeans.newtests.AbstractUnitTest.startContainer(AbstractUnitTest.java:126)
      ... 25 more
      Caused by: org.apache.webbeans.exception.inject.InconsistentSpecializationException: Specialized bean for class : class org.apache.webbeans.newtests.specalization.disabledspecialization.MockLoginService is not enabled in the deployment.
      at org.apache.webbeans.util.WebBeansUtil.configureSpecializations(WebBeansUtil.java:662)
      at org.apache.webbeans.util.WebBeansUtil.configureSpecializations(WebBeansUtil.java:632)
      at org.apache.webbeans.config.BeansDeployer.checkSpecializations(BeansDeployer.java:695)

      Attachments

        Issue Links

          Activity

            People

              struberg Mark Struberg
              struberg Mark Struberg
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: