7 Replies Latest reply on Jan 10, 2015 11:30 PM by Roger Parkinson

    Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache

    Michael Anstis Newbie

      Hello,

       

      I was in the throws of kicking the tyres of Drools Workbench on Wildfly 8.1.0.Final and encountered the following warnings:-

       

      16:23:54,840 WARN  [EventDispatcher] (default task-31) Did not find a way to clear Weld's event observer cache. Some CDI events may be undeliverable to clients. Problematic BeanManagerImpl is class org.jboss.weld.bean.builtin.BeanManagerProxy: java.lang.IllegalArgumentException: java.lang.ClassCastException@45cecdea

        at sun.reflect.GeneratedMethodAccessor63.invoke(Unknown Source) [:1.7.0_51]

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_51]

        at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_51]

        at org.jboss.errai.cdi.server.events.EventDispatcher.clearBeanManagerObserverCaches(EventDispatcher.java:245) [errai-weld-integration-2.4.4.Final.jar:2.4.4.Final]

        at org.jboss.errai.cdi.server.events.EventDispatcher.callback(EventDispatcher.java:118) [errai-weld-integration-2.4.4.Final.jar:2.4.4.Final]

        at org.jboss.errai.bus.server.DeliveryPlan.deliver(DeliveryPlan.java:47) [errai-bus-2.4.4.Final.jar:2.4.4.Final]

        at org.jboss.errai.bus.server.ServerMessageBusImpl.sendGlobal(ServerMessageBusImpl.java:284) [errai-bus-2.4.4.Final.jar:2.4.4.Final]

        at org.jboss.errai.bus.server.SimpleDispatcher.dispatchGlobal(SimpleDispatcher.java:46) [errai-bus-2.4.4.Final.jar:2.4.4.Final]

        at org.jboss.errai.bus.server.service.ErraiServiceImpl.store(ErraiServiceImpl.java:97) [errai-bus-2.4.4.Final.jar:2.4.4.Final]

        at org.jboss.errai.bus.server.service.ErraiServiceImpl.store(ErraiServiceImpl.java:114) [errai-bus-2.4.4.Final.jar:2.4.4.Final]

        at org.jboss.errai.bus.server.servlet.DefaultBlockingServlet.doPost(DefaultBlockingServlet.java:140) [errai-bus-2.4.4.Final.jar:2.4.4.Final]

       

      Is this a known issue on Wildfly?

       

      Thanks,

       

      Mike

        • 1. Re: Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache
          Christian Sadilek Master

          Hi Michael,

           

          Yes, this is a known issue. I already talked to Maciej about this: https://issues.jboss.org/browse/ERRAI-750

           

          tl;dr:


          - Upgrading to Errai 3.0 will work right away (the existing workaround has been improved to work with WildFly 8.1)

          - We could backport the improved workaround to 2.4 and release 2.4.5.Final

          - The cleanest solution would require you to upgrade to Errai 3.1.0 (where to workaround was replaced with a proper implementation, but this requires CDI 1.1 (WildFly 8.0 or higher))


          Cheers,

          Christian


          P.S. note that upgrading errai-weld-integration should be sufficient.

          • 2. Re: Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache
            Siegbert Kurtz Newbie

            Hi Christian, Maciej,

             

            in which version of jbpm (the workbench) it will be fixed and when?

            In the current 6.1.0.final there is still the 2.4 included?

             

            Thanks.

             

            Regards

            Siegbert

            • 3. Re: Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache
              SANJAY GAUTAM Expert

              Hi Siegbert .

               

              Were you able to resolve the issue ?

              Please share what actually worked for you finally. My JBPM deployement for the wildfly 8.2-Final is also throwing the same error and was wondering if above suggestion will solve the issue.

              Although while i read I am trying to solve it by above suggestion provided by @Christan but if you already was able to resolve it please do share the details.

               

              thanks

              Sanjay Gautam

              • 4. Re: Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache
                SANJAY GAUTAM Expert

                Please let us know specifics of the answer which helps the newbees as well as increase the value of the answer. Sorry to be little loud on it. :-(

                I went to the errai website below

                 

                http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22org.jboss.errai%22%20AND%20v%3A%223.1.0.Final%22

                 

                Here it looks like that two issues talking about.

                1. BPM having ERRAI2.4.4 version packed with JBPM6.1.0

                2. WildFly 8.1.0 In general having issue with the Errai which come out of the box.

                 

                It will be great help if @Christian can help to provide specific information.

                For fixing number 1 issue I believe I will have to pack all these erraixxx.jars of verion 3.1.0FInal I believe ? ? is that correct ?

                For Fixing the Number 2 Issue I believe I have to update the modules in the wildfly 8.2.-0 verions .

                 

                Please confirm if thats the correct understanding.

                 

                jbmpn-console : Do you think I have to change complete set ? I see there are new jars come up in the latest errai how do they map with below mentioned errai files ?

                errai.png

                 

                Wild Fly Details

                I cant find anything explicit in the file path related with errai in the modules folder Please suggest what needs to be done out there.

                 

                thanks in advance .

                Sanjay Gautam

                • 5. Re: Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache
                  Christian Sadilek Master

                  Hi Sanjay,

                   

                  I think I already provided all relevant information on this topic above (see the linked JIRA, email thread, etc.).

                   

                  This issue does not affect all of Errai, only a single .jar (errai-weld-integration.jar).

                   

                  Here's the summary:

                  errai-weld-integration 3.0.4 will work with CDI <= 1.1 (WildFly 8.1.0 or older)

                  errai-weld-integration 3.1.x will work with CDI >= 1.1 (WildFly 8.2.0 or newer)

                   

                  I am also not aware of any outstanding issue in that regard.

                   

                  Cheers,

                  Christian

                  • 6. Re: Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache
                    SANJAY GAUTAM Expert

                    Thanks for the confirming to the point details. I did after a long trial and error figured out the same. I was able to fix the issue. It works perfect now. - Thanks.

                    For the benefits of the others as Christian suggested i update all the files errai related with the 2.4.5 version jar files. 

                    • 7. Re: Wildfly 8.1.0.Final: Errai 2.4.4.Final: WARN: Did not find a way to clear Weld's event observer cache
                      Roger Parkinson Newbie

                      Using errai-weld-integration 3.0.4.Final on Widlfly 8.1.0.Final I get:

                       

                      17:24:14,919 INFO  [org.jboss.weld.deployer] (MSC service thread 1-14) JBAS016002: Processing weld deployment kie-wb-6.1.0.Final-wildfly.war

                      17:24:14,963 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-14) MSC000001: Failed to start service jboss.deployment.unit."kie-wb-6.1.0.Final-wildfly.war".POST_MODULE: org.jboss.msc.service.StartException in service jboss.deployment.unit."kie-wb-6.1.0.Final-wildfly.war".POST_MODULE: JBAS018733: Failed to process phase POST_MODULE of deployment "kie-wb-6.1.0.Final-wildfly.war"

                          at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:166) [wildfly-server-8.1.0.Final.jar:8.1.0.Final]

                          at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]

                          at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]

                          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_67]

                          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_67]

                          at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_67]

                      Caused by: java.lang.NoClassDefFoundError: org/jboss/errai/bus/server/util/NotAService

                          at java.lang.Class.getDeclaredConstructors0(Native Method) [rt.jar:1.7.0_67]

                          at java.lang.Class.privateGetDeclaredConstructors(Class.java:2532) [rt.jar:1.7.0_67]

                          at java.lang.Class.getConstructor0(Class.java:2842) [rt.jar:1.7.0_67]

                          at java.lang.Class.newInstance(Class.java:345) [rt.jar:1.7.0_67]

                          at org.jboss.as.weld.deployment.WeldPortableExtensions.tryRegisterExtension(WeldPortableExtensions.java:54)

                          at org.jboss.as.weld.deployment.processors.WeldPortableExtensionProcessor.loadAttachments(WeldPortableExtensionProcessor.java:121)

                          at org.jboss.as.weld.deployment.processors.WeldPortableExtensionProcessor.deploy(WeldPortableExtensionProcessor.java:81)

                          at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:159) [wildfly-server-8.1.0.Final.jar:8.1.0.Final]

                          ... 5 more

                      Caused by: java.lang.ClassNotFoundException: org.jboss.errai.bus.server.util.NotAService from [Module "deployment.kie-wb-6.1.0.Final-wildfly.war:main" from Service Module Loader]

                          at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:213) [jboss-modules.jar:1.3.3.Final]

                          at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:459) [jboss-modules.jar:1.3.3.Final]

                          at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:408) [jboss-modules.jar:1.3.3.Final]

                          at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:389) [jboss-modules.jar:1.3.3.Final]

                          at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:134) [jboss-modules.jar:1.3.3.Final]

                          ... 13 more

                       

                      17:24:14,967 ERROR [org.jboss.as.controller.management-operation] (XNIO-1 task-5) JBAS014613: Operation ("deploy") failed - address: ([("deployment" => "kie-wb-6.1.0.Final-wildfly.war")]) - failure description: {"JBAS014671: Failed services" => {"jboss.deployment.unit.\"kie-wb-6.1.0.Final-wildfly.war\".POST_MODULE" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"kie-wb-6.1.0.Final-wildfly.war\".POST_MODULE: JBAS018733: Failed to process phase POST_MODULE of deployment \"kie-wb-6.1.0.Final-wildfly.war\"

                          Caused by: java.lang.NoClassDefFoundError: org/jboss/errai/bus/server/util/NotAService

                          Caused by: java.lang.ClassNotFoundException: org.jboss.errai.bus.server.util.NotAService from [Module \"deployment.kie-wb-6.1.0.Final-wildfly.war:main\" from Service Module Loader]"}}