glassfish
  1. glassfish
  2. GLASSFISH-13543

Automatic registration of FacesServlet with no JSF annotations

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Duplicate
    • Affects Version/s: 3.1
    • Fix Version/s: None
    • Component/s: jsf
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      13,543

      Description

      Currently JSF runtime is automatically registered for a Java EE 6 WAR if any JSF-known annotation is
      available on a class in the WAR. This makes explicit registration of FacesServlet in web.xml redundant
      and thus fulfills the promise of no-web.xml in Java EE 6 very well.

      However as CDI is the recommended way for JSF backing beans, this means that FacesServlet need to be
      explicitly registered if only @Named is used for backing beans. Thus web.xml need to be present in the
      WAR file.

      FIling this as P2 as this is going to be a common use case in Java EE 6. Registering FacesServlet when
      @Named is present on a class in the WAR file is not the right thing cause a non-JSF framework may be
      used for the front-end. Maybe presence of one or more .XHTML files can trigger registration of
      FacesServlet.

        Issue Links

          Activity

          Hide
          Ryan Lubke added a comment -

          Passing to Ed.

          Show
          Ryan Lubke added a comment - Passing to Ed.
          Hide
          arungupta added a comment -

          Another suggestion is to take ApplicationConfig-like approach taken by JAX-RS. This class can then
          register implementation specific Servlet and still keep the application portable.

          Show
          arungupta added a comment - Another suggestion is to take ApplicationConfig-like approach taken by JAX-RS. This class can then register implementation specific Servlet and still keep the application portable.
          Hide
          Ed Burns added a comment -

          Move to 3.2

          Show
          Ed Burns added a comment - Move to 3.2
          Hide
          Ed Burns added a comment -

          This was fixed in JSF 2.1

          Show
          Ed Burns added a comment - This was fixed in JSF 2.1
          Hide
          Ed Burns added a comment -

          Ahh, Arun, I see you are correct. I will re-open this bug.

          Show
          Ed Burns added a comment - Ahh, Arun, I see you are correct. I will re-open this bug.
          Hide
          Ed Burns added a comment -

          I have requested a meeting with Shing Wai to give me some help on this issue.

          Show
          Ed Burns added a comment - I have requested a meeting with Shing Wai to give me some help on this issue.
          Hide
          Ed Burns added a comment -

          Downgrading from Critical to Major.

          Show
          Ed Burns added a comment - Downgrading from Critical to Major.
          Hide
          Manfred Riem added a comment -

          Closing as duplicate. See associated issue for resolution.

          Show
          Manfred Riem added a comment - Closing as duplicate. See associated issue for resolution.

            People

            • Assignee:
              Ed Burns
              Reporter:
              arungupta
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: