JavaServer Faces - JSF 1.1 on Tomcat 5.0 - SEVERE: Error listenerStart

Hi all,
First of all, I am new to JSF. i had created a sample project using JSF & included the jars needed ---
(commons-beanutils-1.7.0,commons-codec-1.3,commons-collections-3.2,commons-digester-1.8,commons-discovery-0.4,commons-el-1.0,commons-lang-2.1,commons-logging-1.1.1,commons-validator,myfaces-api-1.2.6,myfaces-impl-1.2.6.)
when i try to run the server, i am getting error as
SEVERE: Error listenerStart
and i am pasting the entire log for your reference--
Mar 23, 2009 4:37:26 PM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8081
Mar 23, 2009 4:37:26 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1016 ms
Mar 23, 2009 4:37:26 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Mar 23, 2009 4:37:26 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/5.0.28
Mar 23, 2009 4:37:26 PM org.apache.catalina.core.StandardHost start
INFO: XML validation disabled
Mar 23, 2009 4:37:27 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Mar 23, 2009 4:37:27 PM org.apache.catalina.core.StandardContext start
SEVERE: Context startup failed due to previous errors
Mar 23, 2009 4:37:27 PM org.apache.myfaces.config.annotation.DefaultLifecycleProviderFactory getLifecycleProvider
INFO: No ExternalContext using fallback LifecycleProvider.
Mar 23, 2009 4:37:27 PM org.apache.myfaces.config.annotation.DefaultLifecycleProviderFactory getLifecycleProvider
INFO: Using LifecycleProvider org.apache.myfaces.config.annotation.NoAnnotationLifecyleProvider
Mar 23, 2009 4:37:27 PM org.apache.catalina.core.StandardHost getDeployer
INFO: Create Host deployer for direct deployment ( non-jmx )
Mar 23, 2009 4:37:27 PM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8081
Mar 23, 2009 4:37:27 PM org.apache.jk.common.ChannelSocket init
INFO: JK2: ajp13 listening on /0.0.0.0:8009
Mar 23, 2009 4:37:27 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/31 config=null
Mar 23, 2009 4:37:27 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 1141 ms
& this is my WEB.XML
<?xml version=+"1.0"+ encoding=+"UTF-8"+?>
<web-app id=+"WebApp_ID"+ version=+"2.4"+ xmlns=+"http://java.sun.com/xml/ns/j2ee"+ xmlns:xsi=+"http://www.w3.org/2001/XMLSchema-instance"+ xsi:schemaLocation=+"http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"+>
<display-name>
Rich_4_New</display-name>
<listener>
<listener-class>org._apache_._myfaces_._webapp_.StartupServletContextListener</listener-class>
</listener>
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>
javax.faces._webapp_.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.faces</url-pattern>
</servlet-mapping>
<welcome-file-list>
<welcome-file>index._jsp_</welcome-file>
</welcome-file-list>
</web-app>
suggestions are much appreciated....& ASAP...
Thanks in advance.

I had a similar problem on OC4J. For some crazy reason, Oracle still bundles their own XML parser (I say still. It's OC4J 10.1.3 we have in production, so we're just a wee bit behind the curve). At any rate, I had to tell OC4j not to use Oracle's XML parser and just the one bundle with the JRE (1.5). IIRC (and I should know this since I work on Mojarra :), that's caused by an older version of JAXB, so I think you're on the right track. You might check to see if Tomcat 6 bundles JAXB. If it does, you'll need to remove it or update it. If you're on 1.5 or greater, I don't think you need to have that in the app server lib anyway, as the JDK/JRE bundles it.
Hope that helps. :)

Similar Messages

  • Deploy problem of JSF WebApp on Tomcat 5.5.17 SEVERE: Error listenerStart

    Hi there,
    My installation configuration is as followed:
    Tomcat5.5.17 using the following connector:
        <Connector
          port="8083"
          maxHttpHeaderSize="8192"
          maxThreads="150"
          minSpareThreads="25"
          maxSpareThreads="75"
          enableLookups="true"
          redirectPort="8080"
          acceptCount="100"
          debug="1"
          connectionTimeout="20000"
          disableUploadTimeout="true" />tomcat-user.xml defines:
    <?xml version='1.0' encoding='utf-8'?>
    <tomcat-users>
      <role rolename="manager"/>
      <role rolename="admin"/>
      <user username="tomcat" password="tomcat" roles="manager,admin"/>
    </tomcat-users>Tomcat starts up correctly with the following url and is runs while deploying:
    http://localhost:8083/manager/html
    My WebApp is a simple Test App and is the following:
    index.html:
    <html>
       <head>
          <meta http-equiv="Refresh" content= "0; URL=index.faces"/>
          <title>Start Web Application</title>
       </head>
       <body>
          <p>Please wait for the web application to start.</p>
       </body>
    </html>
    index.jsp:
    <html>
       <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
       <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
       <f:view>
          <head>                 
             <title>A Simple JavaServer Faces Application</title>
          </head>
          <body>
             <h:form>
                <h3>Please enter your name and password.</h3>
                <table>
                   <tr>
                      <td>Name:</td>
                      <td>
                         <h:inputText value="#{user.name}"/>
                      </td>
                   </tr>            
                   <tr>
                      <td>Password:</td>
                      <td>
                         <h:inputSecret value="#{user.password}"/>
                      </td>
                   </tr>
                </table>
                <p>
                   <h:commandButton value="Login" action="login"/>
                </p>
             </h:form>
          </body>
       </f:view>
    </html>welcome.jsp:
    <html>
       <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
       <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
       <f:view>
          <head>              
             <title>A Simple JavaServer Faces Application</title>
          </head>
          <body>
             <h:form>
                <h3>
                   Welcome to JavaServer Faces,
                   <h:outputText value="#{user.name}"/>!
                </h3>
             </h:form>
          </body>     
       </f:view>
    </html>
    UserBean.java:
    package com.jsfcore;
    public class UserBean {
         private String name;
         private String password;
         public UserBean() {
              super();
         private String getName() {
              return this.name;
         private void setName(String name) {
              this.name = name;
         private String getPassword() {
              return this.password;
         private void setPassword(String password) {
              this.password = password;
    web.xml:
    <?xml version="1.0"?>
    <!DOCTYPE web-app PUBLIC
       "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
       "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
       <display-name>Simple Login Applications</display-name>
       <servlet>
          <servlet-name>Faces Servlet</servlet-name>
          <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
          <load-on-startup>1</load-on-startup>
       </servlet>  
       <servlet-mapping>
          <servlet-name>Faces Servlet</servlet-name>
          <url-pattern>/faces/*</url-pattern>
       </servlet-mapping> 
       <welcome-file-list>
          <welcome-file>index.html</welcome-file>
       </welcome-file-list>
    </web-app>
    faces-config.xml:
    <?xml version="1.0"?>
    <!DOCTYPE faces-config PUBLIC
      "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN"
      "http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
    <faces-config>
       <navigation-rule>
          <from-view-id>/index.jsp</from-view-id>
          <navigation-case>
             <from-outcome>login</from-outcome>
             <to-view-id>/welcome.jsp</to-view-id>
          </navigation-case>
       </navigation-rule>
       <managed-bean>
          <managed-bean-name>user</managed-bean-name>
          <managed-bean-class>com.corejsf.UserBean</managed-bean-class>
          <managed-bean-scope>session</managed-bean-scope>
       </managed-bean>
    </faces-config>I have downloaded jsf-1_1_01.zip and installed it.
    I have downloaded java_ee_sdk-5-windows.exe and installed it too.
    Path login/WEB-INF/lib contains the following jars:
    jsf/lib/jsf-api.jar
    jsf/lib/jsf-impl.jar
    tomcat/servler/lib/commons-digester.jar (fr. tomcat 4.1.3)
    tomcat/server/lib/commons-beanutils.jar (fr. tomcat 4.1.3)
    tomcat/webapps/jsp-examples/lib/jstl.jar (fr. tomcat 5.5.17)
    tomcat/webapps/jsp-examples/lib/standard.jar (fr. tomcat 5.5.17)
    The compilation and deployment was successful.
    With my build.xml, I have deployed the login.war file into path
    tomcat/webapps
    The login.war file was unpacked into the normal web application directory structure.
    That is where the problem appeared with the output display on the consol:
    Jul 27, 2006 11:10:39 AM org.apache.coyote.http11.Http11BaseProtocol init
    INFO: Initializing Coyote HTTP/1.1 on http-8083
    Jul 27, 2006 11:10:39 AM org.apache.coyote.http11.Http11BaseProtocol init
    INFO: Initializing Coyote HTTP/1.1 on http-8082
    Jul 27, 2006 11:10:39 AM org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 750 ms
    Jul 27, 2006 11:10:40 AM org.apache.catalina.core.StandardService start
    INFO: Starting service Catalina
    Jul 27, 2006 11:10:40 AM org.apache.catalina.core.StandardEngine start
    INFO: Starting Servlet Engine: Apache Tomcat/5.5.17
    Jul 27, 2006 11:10:40 AM org.apache.catalina.core.StandardHost start
    INFO: XML validation disabled
    Jul 27, 2006 11:10:41 AM org.apache.catalina.startup.HostConfig deployWAR
    INFO: Deploying web application archive login.war
    Jul 27, 2006 11:10:41 AM org.apache.catalina.core.StandardContext start
    SEVERE: Error listenerStart
    Jul 27, 2006 11:10:41 AM org.apache.catalina.core.StandardContext start
    SEVERE: Context [login] startup failed due to previous errors
    Jul 27, 2006 11:10:42 AM org.apache.coyote.http11.Http11BaseProtocol start
    INFO: Starting Coyote HTTP/1.1 on http-8083
    Jul 27, 2006 11:10:42 AM org.apache.coyote.http11.Http11BaseProtocol start
    INFO: Starting Coyote HTTP/1.1 on http-8082
    Jul 27, 2006 11:10:42 AM org.apache.catalina.storeconfig.StoreLoader load
    INFO: Find registry server-registry.xml at classpath resource
    Jul 27, 2006 11:10:43 AM org.apache.catalina.startup.Catalina start
    INFO: Server startup in 3047 ms
    I am unable to start the login application on the Tomcat Web Application Manager.
    The following Message appears on top:
    FAIL - Application at context path /login could not be started
    Let me say, that I have already continued developing more code for this application up to this point and wanted to test in the meantime. Since I had this failure I mentioned above, I have stripped down the application to the code above and I still have no success. I cannot go further until I am getting this very small application up and running on the server.
    Is anybody out there who could give me a hint to solve this problem?
    I really appreciate any hints, since I am circeling around the problem for guit a while.
    Thanks very much
    Markus

    Hi there,
    My installation configuration is as followed:
    Tomcat5.5.17 using the following connector:
        <Connector
          port="8083"
          maxHttpHeaderSize="8192"
          maxThreads="150"
          minSpareThreads="25"
          maxSpareThreads="75"
          enableLookups="true"
          redirectPort="8080"
          acceptCount="100"
          debug="1"
          connectionTimeout="20000"
          disableUploadTimeout="true" />tomcat-user.xml defines:
    <?xml version='1.0' encoding='utf-8'?>
    <tomcat-users>
      <role rolename="manager"/>
      <role rolename="admin"/>
      <user username="tomcat" password="tomcat" roles="manager,admin"/>
    </tomcat-users>Tomcat starts up correctly with the following url and is runs while deploying:
    http://localhost:8083/manager/html
    My WebApp is a simple Test App and is the following:
    index.html:
    <html>
       <head>
          <meta http-equiv="Refresh" content= "0; URL=index.faces"/>
          <title>Start Web Application</title>
       </head>
       <body>
          <p>Please wait for the web application to start.</p>
       </body>
    </html>
    index.jsp:
    <html>
       <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
       <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
       <f:view>
          <head>                 
             <title>A Simple JavaServer Faces Application</title>
          </head>
          <body>
             <h:form>
                <h3>Please enter your name and password.</h3>
                <table>
                   <tr>
                      <td>Name:</td>
                      <td>
                         <h:inputText value="#{user.name}"/>
                      </td>
                   </tr>            
                   <tr>
                      <td>Password:</td>
                      <td>
                         <h:inputSecret value="#{user.password}"/>
                      </td>
                   </tr>
                </table>
                <p>
                   <h:commandButton value="Login" action="login"/>
                </p>
             </h:form>
          </body>
       </f:view>
    </html>welcome.jsp:
    <html>
       <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
       <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
       <f:view>
          <head>              
             <title>A Simple JavaServer Faces Application</title>
          </head>
          <body>
             <h:form>
                <h3>
                   Welcome to JavaServer Faces,
                   <h:outputText value="#{user.name}"/>!
                </h3>
             </h:form>
          </body>     
       </f:view>
    </html>
    UserBean.java:
    package com.jsfcore;
    public class UserBean {
         private String name;
         private String password;
         public UserBean() {
              super();
         private String getName() {
              return this.name;
         private void setName(String name) {
              this.name = name;
         private String getPassword() {
              return this.password;
         private void setPassword(String password) {
              this.password = password;
    web.xml:
    <?xml version="1.0"?>
    <!DOCTYPE web-app PUBLIC
       "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
       "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
       <display-name>Simple Login Applications</display-name>
       <servlet>
          <servlet-name>Faces Servlet</servlet-name>
          <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
          <load-on-startup>1</load-on-startup>
       </servlet>  
       <servlet-mapping>
          <servlet-name>Faces Servlet</servlet-name>
          <url-pattern>/faces/*</url-pattern>
       </servlet-mapping> 
       <welcome-file-list>
          <welcome-file>index.html</welcome-file>
       </welcome-file-list>
    </web-app>
    faces-config.xml:
    <?xml version="1.0"?>
    <!DOCTYPE faces-config PUBLIC
      "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN"
      "http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
    <faces-config>
       <navigation-rule>
          <from-view-id>/index.jsp</from-view-id>
          <navigation-case>
             <from-outcome>login</from-outcome>
             <to-view-id>/welcome.jsp</to-view-id>
          </navigation-case>
       </navigation-rule>
       <managed-bean>
          <managed-bean-name>user</managed-bean-name>
          <managed-bean-class>com.corejsf.UserBean</managed-bean-class>
          <managed-bean-scope>session</managed-bean-scope>
       </managed-bean>
    </faces-config>I have downloaded jsf-1_1_01.zip and installed it.
    I have downloaded java_ee_sdk-5-windows.exe and installed it too.
    Path login/WEB-INF/lib contains the following jars:
    jsf/lib/jsf-api.jar
    jsf/lib/jsf-impl.jar
    tomcat/servler/lib/commons-digester.jar (fr. tomcat 4.1.3)
    tomcat/server/lib/commons-beanutils.jar (fr. tomcat 4.1.3)
    tomcat/webapps/jsp-examples/lib/jstl.jar (fr. tomcat 5.5.17)
    tomcat/webapps/jsp-examples/lib/standard.jar (fr. tomcat 5.5.17)
    The compilation and deployment was successful.
    With my build.xml, I have deployed the login.war file into path
    tomcat/webapps
    The login.war file was unpacked into the normal web application directory structure.
    That is where the problem appeared with the output display on the consol:
    Jul 27, 2006 11:10:39 AM org.apache.coyote.http11.Http11BaseProtocol init
    INFO: Initializing Coyote HTTP/1.1 on http-8083
    Jul 27, 2006 11:10:39 AM org.apache.coyote.http11.Http11BaseProtocol init
    INFO: Initializing Coyote HTTP/1.1 on http-8082
    Jul 27, 2006 11:10:39 AM org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 750 ms
    Jul 27, 2006 11:10:40 AM org.apache.catalina.core.StandardService start
    INFO: Starting service Catalina
    Jul 27, 2006 11:10:40 AM org.apache.catalina.core.StandardEngine start
    INFO: Starting Servlet Engine: Apache Tomcat/5.5.17
    Jul 27, 2006 11:10:40 AM org.apache.catalina.core.StandardHost start
    INFO: XML validation disabled
    Jul 27, 2006 11:10:41 AM org.apache.catalina.startup.HostConfig deployWAR
    INFO: Deploying web application archive login.war
    Jul 27, 2006 11:10:41 AM org.apache.catalina.core.StandardContext start
    SEVERE: Error listenerStart
    Jul 27, 2006 11:10:41 AM org.apache.catalina.core.StandardContext start
    SEVERE: Context [login] startup failed due to previous errors
    Jul 27, 2006 11:10:42 AM org.apache.coyote.http11.Http11BaseProtocol start
    INFO: Starting Coyote HTTP/1.1 on http-8083
    Jul 27, 2006 11:10:42 AM org.apache.coyote.http11.Http11BaseProtocol start
    INFO: Starting Coyote HTTP/1.1 on http-8082
    Jul 27, 2006 11:10:42 AM org.apache.catalina.storeconfig.StoreLoader load
    INFO: Find registry server-registry.xml at classpath resource
    Jul 27, 2006 11:10:43 AM org.apache.catalina.startup.Catalina start
    INFO: Server startup in 3047 ms
    I am unable to start the login application on the Tomcat Web Application Manager.
    The following Message appears on top:
    FAIL - Application at context path /login could not be started
    Let me say, that I have already continued developing more code for this application up to this point and wanted to test in the meantime. Since I had this failure I mentioned above, I have stripped down the application to the code above and I still have no success. I cannot go further until I am getting this very small application up and running on the server.
    Is anybody out there who could give me a hint to solve this problem?
    I really appreciate any hints, since I am circeling around the problem for guit a while.
    Thanks very much
    Markus

  • JSF 1.2 and Tomcat 6.0.16, error parsing 'jsf-ri-runtime.xml'

    I am working on an application that used jsf 1.1 but would like to move to jsf 1.2. I've added the 1.2 jars (jsf-api.jar and jsf-impl.jar) and jstl-1.2.jar to the app. When I deploy to tomcat 6, i get the following error:
    15-Feb-2008 11:30:36 org.apache.catalina.core.StandardContext listenerStart
    SEVERE: Exception sending context initialized event to listener instance of class com.sun.faces.config.ConfigureListener
    com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! Unable to parse document 'jar:file:/C:/servers/apache-tomcat-6.0.16/webapps/myWebApp/WEB-INF/lib/jsf-impl-1.2.jar!/com/sun/faces/jsf-ri-runtime.xml': This parser does not support specification "null" version "null"
    at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:212)
    at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:174)
    at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
    at org.apache.catalina.core.StandardContext.start(StandardContext.java:4350)
    at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
    at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
    at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
    at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:829)
    at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:718)
    at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490)
    at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1147)
    at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
    at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
    at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
    at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
    at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
    at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
    at org.apache.catalina.core.StandardService.start(StandardService.java:516)
    at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
    Caused by: com.sun.faces.config.ConfigurationException: Unable to parse document 'jar:file:/C:/servers/apache-tomcat-6.0.16/webapps/myWebApp/WEB-INF/lib/jsf-impl-1.2.jar!/com/sun/faces/jsf-ri-runtime.xml': This parser does not support specification "null" version "null"
    at com.sun.faces.config.ConfigManager$ParseTask.call(ConfigManager.java:409)
    at com.sun.faces.config.ConfigManager$ParseTask.call(ConfigManager.java:353)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
    at java.lang.Thread.run(Thread.java:619)
    I thought this would have something to do with the xml parser so i added jaxb and jaxp to the application but I still get the same error. Can anyone help? Is there a possibility that a library in the app is overriding jaxb/jaxp?

    I had a similar problem on OC4J. For some crazy reason, Oracle still bundles their own XML parser (I say still. It's OC4J 10.1.3 we have in production, so we're just a wee bit behind the curve). At any rate, I had to tell OC4j not to use Oracle's XML parser and just the one bundle with the JRE (1.5). IIRC (and I should know this since I work on Mojarra :), that's caused by an older version of JAXB, so I think you're on the right track. You might check to see if Tomcat 6 bundles JAXB. If it does, you'll need to remove it or update it. If you're on 1.5 or greater, I don't think you need to have that in the app server lib anyway, as the JDK/JRE bundles it.
    Hope that helps. :)

  • Working jmeter javaserver faces jsf - how create an XPath to keep the ViewS

    Hi all,
    I've searching and I found this http://forums.sun.com/thread.jspa?threadID=664673&messageID=4418665#4418665 ...
    I manage to test JSF 1.2 using JMeter but there is a trick, even if you are using the HTTP Proxy:
    1) The first HTTP request get a page with a form.
    2) The second request perform a JSF action on this form.
    Make sure that you are sending the value of javax.faces.ViewState found in the from at the second request, otherwise the View restore may fail.
    For this, create a XPath extractor. The XPath query is: //input/@value. Choose a reference name, ViewState per example.
    In the second http request, send a javax.faces.ViewState parameter with the value ${ViewState}.
    I spent a couple of ours finding this. I am not a JSF1.2 seasoned programmer but I hope it will help saving you time. The answer seems to be rigth, however I don't get the meaning of how do the XPath creation...
    I just wanna to know how can I do the creation XPath on Jmeter (to use on jsf) pass by pass... (just like a tutorial) I read the text above but I can't get any the understanding....
    The purpose is the same keep and use the javax.faces.ViewState
    thanks in advance,

    I have an additional question/problem.
    Running JBOSS 4.2, JSF 1.2 and JMETER 2.3.2
    Scenario 1 (SUCCESS):
    I run one thread and one threadgroup, regex/xpath return the "ViewState" value correctly and the test runs perfectly until I stop it.
    Scenarion 2 (FAILURE):
    I run multiple threads and one threadgroup, regex/xpath eventually return the DEFAULT value instead the "ViewState" value to all but one thread. The more threads the faster they fail. It really seems like there is a threading issue.
    In any case only one thread will remain running correctly.

  • When to move from Struts to JavaServer Faces

    Hi all,
    we've noticed that JavaServer Faces appears to be the future for Model-View-Controller (MVC) framework, and eventually make Struts obsolete (IMHO).
    we are just about to embark on a new project and wondering if JavaServer Faces (JSF) is mature enough to deserve our attention, or should we wait until its full production release.
    any comments will be appreciated.
    regards,
    Trajano

    I would say if it's not at a full production release yet, then wait. If you have a real world app, it's not worth using a beta system to run it on. At least not without some thorough testing of your own, but only you know what your application needs.

  • Problem with JSF 1.2 and Tomcat 6

    Hello guys,
    I have here:
    Tomcat 6.0.10
    JSF 1.2_04_b10_p01
    I followed these steps without success:
    http://forum.java.sun.com/thread.jspa?threadID=787962
    http://forum.java.sun.com/thread.jspa?threadID=5156242
    Here what I did:
    1) Removed the following line in $TOMCAT_HOME/conf/server.xml
    <Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on" />2) Add the following lines to $TOMCAT_HOME/conf/web.xml
         <context-param>
         <param-name>com.sun.faces.expressionFactory</param-name>
         <param-value>org.apache.el.ExpressionFactoryImpl</param-value>
         </context-param>3) Add the following libs to $TOMCAT_HOME/lib
    jsf-api.jar
    jsf-impl.jar
    jstl-1.2.jar
    4) Add the following lines to $MYAPP/WEB-INF/web.xml
         <listener>
              <listener-class>
                   com.sun.faces.config.ConfigureListener
              </listener-class>
         </listener>
         <listener>
              <listener-class>
                   com.sun.faces.application.WebappLifecycleListener
              </listener-class>
         </listener>And here is "the final product":
    INFO: Initializing Sun's JavaServer Faces implementation (1.2_04-b10-p01) for context '/protocolo'
    10/04/2007 08:18:47 com.sun.faces.config.ConfigureListener registerELResolverAndListenerWithJsp
    SEVERE: Error Instantiating ExpressionFactory
    java.lang.ClassCastException: org.apache.el.ExpressionFactoryImpl cannot be cast to javax.el.ExpressionFactory
         at com.sun.faces.config.ConfigureListener.registerELResolverAndListenerWithJsp(ConfigureListener.java:1563)
         at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:419)
         at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3827)
         at org.apache.catalina.core.StandardContext.start(StandardContext.java:4336)
         at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:761)
         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:741)
         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
         at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:825)
         at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:714)
         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490)What I need to do? Someone can help me?
    Thank you.

    Thank you for the answer rlubke,
    Well this happened because I had compiled the project with the jstl-1.1
    The workaround to make jsf 1.2 run on tomcat 6 really works.
    But now I have a problem because the JNDI tree in tomcat is read-only ( ro )
    and I need to bind a object in the JNDI so an exception happens:
    WARNING: Ocorreu um erro inexperado:
    javax.naming.NamingException: Context is read only
             at org.apache.naming.NamingContext.checkWritable(NamingContext.java:903)
             at org.apache.naming.NamingContext.bind(NamingContext.java:831)
             at org.apache.naming.NamingContext.bind(NamingContext.java:171)
             at org.apache.naming.NamingContext.bind(NamingContext.java:187)
             at org.apache.naming.SelectorContext.bind(SelectorContext.java:171)
             at javax.naming.InitialContext.bind(InitialContext.java:400)Here is the code:
    try{
         Context newContext = new InitialContext();
         newContext.bind( dataSourceWrappedID, wrappedDs );
         newContext.close();
    }catch(NameAlreadyBoundException nabe){
         // ok no problem..
    }catch(NamingException ne){
         if ( log.isWarnEnabled() ){
              log.warn("Ocorreu um erro inexperado:", ne);
    }You know how to make the JNDI tree in tomcat read-write ?
    Thank you a ton. :-)

  • How do I use Struts Tiles with JavaServer Faces?

    I want to use JavaServer Faces and need something like tiles.
    Is it right that tiles is for struts what Portlets is for JavaServer Faces?
    Do I have to use Portlets or is there something else?
    What Do I have to do to use Portlets?
    Do I have to use any "engines" or something like that?
    Thanks

    Miikee_
    I guess you understood me wrong!
    JSF RI (and also MyFaces) are implementation of JavaServer Faces Spec.
    Each JSF app needs to be deployed inside of a Servlet Container.
    (like Tomcat). An no, they aren't coming up with an own servlet engine.
    But... you can also run MyFaces and the RI inside of an portlet container
    (eg pluto) instead of Servlet Container.
    HTH,
    Matthias

  • A question about Lifecycle of a JavaServer Faces.

    hello all
    i read "The JavaServer� Faces Technology Tutorial",and mazed about Lifecycle of a JavaServer Faces.
    It explains each of these lifecycle phases using the guessNumber example.
    and if i submit the greeting.jsp ,who can give me particular about the jsf done in order....and the first step :Reconstitute Component Tree reconstitute greeting.jsp 's component tree or response.jsp?..

    thanks!
    i have another question:when the action event or A value-changed event occured,any Standard Request Processing Lifecycle begin?and the step of Reconstitute Component Tree occured?and when occur action event and when occur application event if a button or hyperlink is clicked?and what differentness between the processing to action event and application event by jsf?

  • Javaserver faces rendering ui in jdev ide

    Hello, does anyone has experienced with the JavaServer Faces release 1.1_01 FCS, that the cardemo or other jsf application doesn't render the ui components in jdev 9.0.5.2 ide, having of course "execute tags in jsp visual editor" checked ?
    I hope ORACLE will provide very soon some enhancement in the jdev IDE to help building jsp app with jsf tags.
    Thank's for anyhelp or advice

    You can get an early access preview of the ADF Faces support here:
    http://www.oracle.com/technology/products/jdev/htdocs/partners/addins/exchange/jsf/index.html

  • Download javaServer faces business objects enterprise

    Post Author: gzofera
    CA Forum: JAVA
    hello, where do I download the javaServer face enterprise business objects?
    I am preparing an environment to start customizing web intelligence, and I lost well as to libraries, tools, etc.. which FDI sweat, ECLIPSE? NETBEANS? OTHER? WHERE THE PLUGINS FOR MEETING SET THE SDK? is there any tool that characterizes the Gazette to customize the WEBI? thanks

    Post Author: amr_foci
    CA Forum: JAVA
    i didnt know that there is something like that from Business Objects,  thats work in JSF layer
    but you can check you ESD if you've an account
    https://businessobjects.subscribenet.com/control/bobj/login
    good luck

  • [ANNOUNCE] JavaServer Faces Resources Page

    Hi Everyone,
    I've compiled a list of everything related to JavaServer Faces and put a page on my website for it.
    Here it is:
    http://www.jamesholmes.com/JavaServerFaces/
    If you see anything that I've missed, feel free to drop me a line.
    -James
    [email protected]

    well did you notice that JSF EA4 has just been released ?
    I have one more link (but in french) :
    http://www.builder.fr/story/0,,t541-s2134284,00.html
    It says "Struts is dead, live JSF" (bad translation maybe...)

  • Has JavaServer Faces reached beta?

    I know---please forgive my sarcasm. (I'm sure you've been at this point, too, in your programming career. I'll just vent a little.) I've only spent several days trying to create a simple page I could have coded in a couple of hours in any given language---Java, C++, 80x86 assembler---but not JavaServer Faces.
    Has anyone created any real applications in JSF? It's practically unusable in the real world. I'm about to throw it all away for JSP and JSTL. Here's why:
    * I can't pass parameters to bean methods in the expression language.
    * dataTable can't create <th> except in a header facet, and a header facet can't access data being iterated.
    * There's no way to specify different styles for different <th> elements in a dataTable.
    * There's no way to specify a unique style (rather than the simple alternating styles) for a dataTable row.
    * JSF beans aren't available to the JSTL expression language unless you go through ugly hacks (such as outputting a JSF bean method to a dummy JSTL variable) to make sure the JSF backing beans get instantiated.
    * If any non-JSF stuff (including JSTL, HTML, verbatim character data, or whatever) is present in a JSF page, one has to tediously make sure that a special, seemingly-arbitrary hierarchy of subviews are in place---and even then it's not clear if you're following the spec or just managed to randomly find a combination that worked. Otherwise, all the information gets rendered out of order and out of hierarchy.
    * Don't even think about getting JSTL iteration elements to work with any of this.
    * commandLink still doesn't work in JSF 1.1_01.
    I'd go on, but I need to go back to taking JSF out of the single page I've been working on for days.
    Thanks for listening,
    Garret

    * dataTable can't create <th> except in a header
    facet, and a header facet can't access data being
    iterated.I've no idea why the heck you think a header facet
    should be able to access data that's being iterated.
    That makes no sense to me at all. A header is
    explicltly and, to me at least, obviously not part
    of per-row iteration!Read both parts of that comment together---what I'm really wanting is to be able to get a <th>, and the only way to do that is with a header facet. Here's an example off the top of my head:
    <h1>Book Metadata</h1>
    <table>
    <tr><th>Author</th> <td>Jane Doe</td></tr>
    </table>
    Here the row header is from a list of arbitrary book metadata---we don't know ahead of time what metadata properties the book has. Maybe it has two authors. Maybe it has five creation dates.
    It seems as though your frustrations mostly boil
    down to:
    (1) You hate <h:dataTable>, and find it too limiting.
    Well, it's one of the first JSF element's I've tried (after commandLink, of course). Maybe all of the others work just fine and are powerful.
    (2) You're trying to mix JSTL and JSF, and are
    surprised this doesn't work.
    For #2, it's a known and much-documented thing, so I
    can't understand why you're surprised.
    However documented it is, I'm surprised that not only does JSF not offer equivalent functionality as JSTL, it removes the ability to use JSTL.
    Garret                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • JavaServer Faces or Struts - New insights anyone?

    Hello Everyone:
    JSP or Struts???!! I'm really lost.
    I've read almost every posting on the subject (on this and other forums), yet, I couldn't come with a solid conclusion (may be only inclinations).
    I've started developing my very first real-world web application which is to be up and running by December 2003. I've started reading on both Struts and JavaServer Faces so as to adopt either in that application.
    What complicates things is that I'm a new comer to the web-application world in general (let alone Struts and JSF).
    I'm inclined to use JSF (as it seems that it would be gaining more support and popularity in the near future), yet, It's still in the EA form, while Struts is matured and already popular.
    I'm in need of a Mentor's advice to direct me to the suitable technology as I regard this first project to be both an investment into my career and a robust/reliable front end to my capabilities.
    Appreciate your responses and suggestions. I also appreciate all your previous posts (especially Craig's ones), and apologize if this is an old topic.
    Kindest regards

    You must have read my posts then.
    I think JSF should be ALLWAYS compared to
    http://borland.com/products/downloads/download_csharpbuilder.html which is free (Borland C#) or
    http://www.asp.net/webmatrix/guidedtour/getstarted/tooloverview.aspx
    at all times, and people should pick the one that is cheaper in production or faster to develop on.
    It would be great to read someplace feature/cost comparison to
    http://borland.com/products/downloads/download_csharpbuilder.html
    I think if people are using EJB and/or Blueprints, they should use JSF (but wait till version 2.0?)
    If they are using Windows Servers, they should use Borland C#
    If you like JSF design and would like open source, this is most like JSF, IMO (note that it could support standards like XUL or X-Forms or WS/SOA):
    http://jakarta.apache.org/ecs
    My choice is this via SOA:
    http://examples.macromedia.com/petmarket/store.html
    Struts does have 6 books out and at least 4 places that offer training on it, and a production track record, it is an open standard, everyone (WW2, Spring, etc.) allways starts w/ "We are like Struts,... only better".
    .V

  • JavaServer Faces Development process

    Are there any guidelines / best practices how a JavaServer Faces development process can
    be established. Mainly I'm worry about the separation between
    HTML designer (page authors) and application developers.
    Is it a "good" procedure to let application developer create a sort of prototype including
    the JSP pages and MockBackingBeans to enable a reasonable
    preview for the page authors?
    Or are there any other recommended approaches, how this can be done?
    Thanks for any help in advance.

    http://www.javaworld.com/javaworld/jw-11-2002/jw-1129-jsf.html
    http://java.sun.com/j2ee/javaserverfaces
    1. Go to www.Google.com or www.yahoo.com
    2. Type JSF or Java Server Faces in search box field
    Please let me know , if you find some!!!

  • JavaServer Faces v1.0 tutorial

    Why sun is not releasing the tutorial for JavaServer Faces V1.0?
    Can anyone of you give me the tutorial for Server Faces V1.0. Any links??
    Regards
    Shaf

    See http://java.sun.com/j2ee/javaserverfaces/reference/docs/index.html, the section 'Articles' for the currently available set of documents.
    Also, http://java.sun.com/j2ee/javaserverfaces/download.html indicates that JSF Tutorial is going to be made available soon (see the sentence after the 'Download JSF 1.0 Reference Implementation' button. I think at this time we should be waiting for it to come to us!!!

Maybe you are looking for

  • F110 use of program.

    Hi SAP Experts, During F110 in printout/data medium TAB, there is a colum for Pragram EG: RFFOAVIS_FPAYM etc.....i am confused to use which one & when. What is the use of this program and in the bottom line List is also there where also there are pro

  • Jdk 1.6

    hi Peter__Lawrey Now l use the jdk1.6.0 ,but l meet some problem as follows: l have install the jdk1.6.0 and jvm but l can not run jdk1.6.0\demo\ (applet)when it show the error message " can not load java jvm from <\bin\server\jvm.dll>" ,My OS is Mic

  • Missing diagram components from component palette in Jdev11

    I've been using JDeveloper 11 for a couple of months and today went to create a sequence diagram and found that I had no sequence components listed in the Component Palette. The only drop-down selection is "My Components" which is empty. I tried this

  • Hi, i cannot open mail 10.4.11

    Hi , I cannot open mail on my mac pro 10.4.11 i have  tried disk utilitys.

  • Moving folder with Applescript

    I am trying to move the contents of a folder to a new location, but whenever I run the code below it moves the parent folder as well? (* now move folders from watched folder to new folder location *) set targetFolder to ((path to desktop folder as Un