Uploaded image for project: 'Weld'
  1. Weld
  2. WELD-996

ClassCastException validating custom Interceptor implementation

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Critical
    • Resolution: Done
    • Affects Version/s: 1.1.2.Final
    • Fix Version/s: 1.1.3.Final
    • Component/s: None
    • Labels:
      None
    • Affects:
      Release Notes

      Description

      Having a custom implementation of the Interceptor interface registered with Weld, the validation always fails if the interceptor happens to intercept a passivation capable bean. Weld incorrectly casts the interceptor to InterceptorImpl which is not valid for extension-provided interceptors.

      java.lang.ClassCastException: org.jboss.seam.classic.intercept.ClassicInterceptor cannot be cast to org.jboss.weld.bean.InterceptorImpl
              at org.jboss.as.weld.services.WeldService.start(WeldService.java:96)
              at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1824) [jboss-msc-1.0.1.GA.jar:1.0.1.GA]
              at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1759) [jboss-msc-1.0.1.GA.jar:1.0.1.GA]
              at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [:1.6.0_24]
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [:1.6.0_24]
              at java.lang.Thread.run(Thread.java:662) [:1.6.0_24]
      Caused by: java.lang.ClassCastException: org.jboss.seam.classic.intercept.ClassicInterceptor cannot be cast to org.jboss.weld.bean.InterceptorImpl
              at org.jboss.weld.bootstrap.Validator.validateInterceptors(Validator.java:171)
              at org.jboss.weld.bootstrap.Validator.validateRIBean(Validator.java:151)
              at org.jboss.weld.bootstrap.Validator.validateBeans(Validator.java:351)
              at org.jboss.weld.bootstrap.Validator.validateDeployment(Validator.java:336)
              at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:404)
              at org.jboss.as.weld.WeldContainer.start(WeldContainer.java:82)
              at org.jboss.as.weld.services.WeldService.start(WeldService.java:89)
              ... 5 more
      

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  jharting Jozef Hartinger
                  Reporter:
                  jharting Jozef Hartinger
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: