ICEfaces-EE
  1. ICEfaces-EE
  2. IPCK-212

EE-Component-Showcase Demo does not run on Tomcat 7

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: EE-2.0.0.Alpha1
    • Component/s: Samples
    • Labels:
      None
    • Environment:
      Tomcat 7

      Description

      When deploying the ee-component-showcase.war file to Tomcat 7 the following error is thrown when trying to access it in the browser:

      javax.faces.view.facelets.TagAttributeException: /showcase.xhtml @24,82 locale="#{localeController.sessionLocale}" Attribute did not evaluate to a String or Locale: null
      at com.sun.faces.facelets.tag.jsf.ComponentSupport.getLocale(ComponentSupport.java:297)
      at com.sun.faces.facelets.tag.jsf.core.ViewHandler.apply(ViewHandler.java:128)
      at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98)
      at com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)
      at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98)
      at com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:86)
      at com.sun.faces.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:152)
      at com.sun.faces.application.view.FaceletViewHandlingStrategy.buildView(FaceletViewHandlingStrategy.java:769)
      at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:100)
      at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
      at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:396)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:306)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:240)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:161)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
      at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:550)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:380)
      at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:284)
      at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:322)
      at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:1684)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:619)

      When deploying the same war file to Tomcat 6 it runs without any issues

        Activity

        Arran Mccullough created issue -
        Ken Fyten made changes -
        Field Original Value New Value
        Salesforce Case []
        Fix Version/s EE-2.0.0.Beta1 [ 10254 ]
        Affects [Sample App./Tutorial]
        Assignee Priority P2
        Assignee Ken Fyten [ ken.fyten ] Patrick Corless [ patrick.corless ]
        Hide
        Patrick Corless added a comment -

        Carlo can you take a look. I don't remember running up against this on my testing. Hopefully it's just someone not specifying a tomcat6 profile in the maven build.

        Show
        Patrick Corless added a comment - Carlo can you take a look. I don't remember running up against this on my testing. Hopefully it's just someone not specifying a tomcat6 profile in the maven build.
        Patrick Corless made changes -
        Assignee Patrick Corless [ patrick.corless ] Carlo Guglielmin [ carlo.guglielmin ]
        Hide
        Carlo Guglielmin added a comment -

        I'm getting the same error (on Tomcat 7.0.2). The referenced line looks like getting the default Locale from the FacesContext Application object may be failing. Not sure why this would be happening unless Tomcat is implementing the spec differently.

        Show
        Carlo Guglielmin added a comment - I'm getting the same error (on Tomcat 7.0.2). The referenced line looks like getting the default Locale from the FacesContext Application object may be failing. Not sure why this would be happening unless Tomcat is implementing the spec differently.
        Hide
        Ted Goddard added a comment - - edited

        It runs on Tomcat 7.0.6, but I'm not sure which is the factor:

        • change made to LocaleController.java to set a default locale to Locale.ENGLISH
        • updating to jsf-api.jar and jsf-impl.jar from ICEfaces trunk lib (be sure not to duplicate the .jars as they have version numbers in the current EE names)

        Recommend updating the .jars first.

        Show
        Ted Goddard added a comment - - edited It runs on Tomcat 7.0.6, but I'm not sure which is the factor: change made to LocaleController.java to set a default locale to Locale.ENGLISH updating to jsf-api.jar and jsf-impl.jar from ICEfaces trunk lib (be sure not to duplicate the .jars as they have version numbers in the current EE names) Recommend updating the .jars first.
        Hide
        Carlo Guglielmin added a comment -

        I've tried the same approach Ted mentioned (ie: defaulting LocaleController and updating the JSF jars from the trunk) and the same error still occurs on Tomcat 7.0.2. Perhaps a Tomcat problem. I'll upgrade to the latest 7.x line and test again.

        Show
        Carlo Guglielmin added a comment - I've tried the same approach Ted mentioned (ie: defaulting LocaleController and updating the JSF jars from the trunk) and the same error still occurs on Tomcat 7.0.2. Perhaps a Tomcat problem. I'll upgrade to the latest 7.x line and test again.
        Hide
        Ken Fyten added a comment -

        Note that with the latest JSF 2.1 preview release Tomcat 7 is not working, that could the root cause here.

        Show
        Ken Fyten added a comment - Note that with the latest JSF 2.1 preview release Tomcat 7 is not working, that could the root cause here.
        Hide
        Ken Fyten added a comment -

        The reverted JSF 2.1 jars should now work fine on Tomcat 7. When deploying and running the compat-component-showcase.war, errors appear in the log indicating an incompatibility with the EL language version used by Tomcat 7 (and intended for use with JSF 2). Likely that the showcase or components are using EL syntax which collides with new reserved words or something.

        Show
        Ken Fyten added a comment - The reverted JSF 2.1 jars should now work fine on Tomcat 7. When deploying and running the compat-component-showcase.war, errors appear in the log indicating an incompatibility with the EL language version used by Tomcat 7 (and intended for use with JSF 2). Likely that the showcase or components are using EL syntax which collides with new reserved words or something.
        Ken Fyten made changes -
        Salesforce Case []
        Assignee Priority P2 P1
        Hide
        Carlo Guglielmin added a comment -

        The problem arises because the dataPaginator uses:

        <ice:dataPaginator for="#

        {for}" ... >

        The #{for}

        doesn't work because it's considered a reserved word, whereas something like #

        {forTable}

        does. We will need to change this tag attribute in dataPager.xhtml and dataPagerInfo.xhtml (perhaps other places too).

        Show
        Carlo Guglielmin added a comment - The problem arises because the dataPaginator uses: <ice:dataPaginator for="# {for}" ... > The #{for} doesn't work because it's considered a reserved word, whereas something like # {forTable} does. We will need to change this tag attribute in dataPager.xhtml and dataPagerInfo.xhtml (perhaps other places too).
        Hide
        Carlo Guglielmin added a comment -

        r26169 - Updated dataPaginator usage to replace the reserved keyword 'for' with 'forTable'. Also updated the associated TLD and usages in both the composite components themselves and the EE showcase.

        This works now but will need to be updated in users apps. The TLD has a reference to the deprecated "for" attribute, so that should help.

        Show
        Carlo Guglielmin added a comment - r26169 - Updated dataPaginator usage to replace the reserved keyword 'for' with 'forTable'. Also updated the associated TLD and usages in both the composite components themselves and the EE showcase. This works now but will need to be updated in users apps. The TLD has a reference to the deprecated "for" attribute, so that should help.
        Carlo Guglielmin made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        Philip Breau added a comment -

        reopening for inclusion into 1.8.2 EE p03

        Show
        Philip Breau added a comment - reopening for inclusion into 1.8.2 EE p03
        Philip Breau made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Philip Breau made changes -
        Assignee Carlo Guglielmin [ carlo.guglielmin ] Philip Breau [ philip.breau ]
        Philip Breau made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Fix Version/s EE-1.8.2.GA_P03 [ 10253 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Assignee Priority P1

          People

          • Assignee:
            Philip Breau
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: