Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-3767

CDI on Tomcat + WELD. BeanManager not found on JNDI

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.3.1.2
    • Fix Version/s: 2.3.3
    • Component/s: Plugin - CDI
    • Labels:
      None
    • Environment:

      Tomcat 6.0.X, 7.0.X
      Weld 1.1.5

      Description

      I followed this instruction http://docs.jboss.org/weld/reference/1.0.0/en-US/html/environments.html in order to add cdi support to tomcat.

      The strut2 cdi plugin does not work because it searches the beanManager with those keys: "java:comp/BeanManager" and "java:app/BeanManager".

      Weld docs says "Tomcat only allows to bind entries to java:comp/env, so the BeanManager is available at java:comp/env/BeanManager".

      Adding the 3rd lookup in the plugin source code makes all works fine.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                rgielen René Gielen
                Reporter:
                marco.malavolta Marco Malavolta
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: