Tomcat 6.0.16 + Trinidad 1.2.8 + RichFaces 3.2.0

Pessoal, sou iniciante em Java/Tomcat/ETC …
Porém estou empenhado em configurar e testar este ambiente : Tomcat 6.0.16 + Trinidad 1.2.8 + RichFaces 3.2.0

Apos instalar o TomCat 6.0.16

Realizei os seguintes passos :

1o. Publiquei o trinidad-blank-1.2.8.war e ao iniciar o tomcat recebi varios erros no catalin e localhost.
2o. Consegui zerar os erros ao utilizar as libs do trinidad-demo-1.2.8.war para a aplicacao blank.
3o. MyFaces OK.

4o. Publiquei os RichFaces 3.2.0 e tentei seguir as instrucoes do “RichFaces Developer Guide”.
http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/docs/devguide/en/html_single/index.html

5o. Resultado. Varios Erros no catalina e localhost.

6o. Zerei os erros ao comentar os filters sugeridos pelo devguide. O web.xml final eh este :

<?xml version = '1.0' encoding = 'ISO-8859-1'?>
<!--
    Licensed to the Apache Software Foundation (ASF) under one
    or more contributor license agreements.  See the NOTICE file
    distributed with this work for additional information
    regarding copyright ownership.  The ASF licenses this file
    to you under the Apache License, Version 2.0 (the
    "License"); you may not use this file except in compliance
    with the License.  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing,
    software distributed under the License is distributed on an
    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    KIND, either express or implied.  See the License for the
    specific language governing permissions and limitations
    under the License.
	   
-->
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
         version="2.5">

  <!-- Use client-side state saving.  In Trinidad, it is an
       optimized, token-based mechanism that is almost always a
       better choice than the standard JSF server-side state saving. -->
  <context-param>
    <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
    <param-value>client</param-value>
    <!--param-value>server</param-value-->
  </context-param>

  <!-- Trinidad by default uses an optimized client-side state saving
       mechanism. To disable that, uncomment the following -->
  <!--context-param>
    <param-name>org.apache.myfaces.trinidad.CLIENT_STATE_METHOD</param-name>
    <param-value>all</param-value>
  </context-param-->

  <!-- Trinidad also supports an optimized strategy for caching some
   view state at an application level, which significantly improves
   scalability.  However, it makes it harder to develop (updates to
   pages will not be noticed until the server is restarted), and in
   some rare cases cannot be used for some pages (see Trinidad
   documentation for more information) -->
  <context-param>
    <param-name>org.apache.myfaces.trinidad.USE_APPLICATION_VIEW_CACHE</param-name>
    <param-value>false</param-value>
  </context-param>

  <!-- If this parameter is enabled, Trinidad will automatically
       check the modification date of your JSPs, and discard saved
       state when they change;  this makes development easier,
       but adds overhead that should be avoided when your application
       is deployed -->
  <context-param>
    <param-name>org.apache.myfaces.trinidad.CHECK_FILE_MODIFICATION</param-name>
    <param-value>true</param-value>
  </context-param>

  <!-- Enables Change Persistence at a session scope.  By default,
       Change Persistence is entirely disabled. The ChangeManager is
       an API, which can persist component modifications (like,
       is a showDetail or tree expanded or collapsed). For providing
       a custom Change Persistence implementation inherit from the 
       Trinidad API's ChangeManager class. As the value you have 
       to use the fullqualified class name. -->
  <context-param>
    <param-name>org.apache.myfaces.trinidad.CHANGE_PERSISTENCE</param-name>
    <param-value>session</param-value>
  </context-param>


  <filter>
    <filter-name>trinidad</filter-name>
    <filter-class>org.apache.myfaces.trinidad.webapp.TrinidadFilter</filter-class>
  </filter>

  <filter-mapping>
    <filter-name>trinidad</filter-name>
    <servlet-name>faces</servlet-name>
  </filter-mapping>


<!--  RichFaces. Mario. 15/07/08 -->
<!--  RichFaces. Mario. 15/07/08 -->
  	<context-param>
		<param-name>org.richfaces.CONTROL_SKINNING</param-name>
		<param-value>enable</param-value>
	</context-param>
    <context-param>
        <param-name>org.richfaces.SKIN</param-name>
        <param-value>blueSky</param-value>
    </context-param>
<!--
    <filter> 
        <display-name>RichFaces Filter</display-name> 
        <filter-name>richfaces</filter-name> 
        <filter-class>org.ajax4jsf.Filter</filter-class> 
    </filter> 
    <filter-mapping> 
        <filter-name>richfaces</filter-name> 
        <servlet-name>Faces Servlet</servlet-name>
        <dispatcher>REQUEST</dispatcher>
        <dispatcher>FORWARD</dispatcher>
        <dispatcher>INCLUDE</dispatcher>
    </filter-mapping>
-->


  <!-- Listener, to allow Jetty serving MyFaces apps -->
  <listener>
    <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
  </listener>

  <!-- Faces Servlet -->
  <servlet>
    <servlet-name>faces</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
  </servlet>
  
  <!-- resource loader servlet -->
  <servlet>
    <servlet-name>resources</servlet-name>
    <servlet-class>org.apache.myfaces.trinidad.webapp.ResourceServlet</servlet-class>
  </servlet>

  <!-- Faces Servlet Mappings -->
  <servlet-mapping>
    <servlet-name>faces</servlet-name>
    <url-pattern>/faces/*</url-pattern>
  </servlet-mapping>
  
  <servlet-mapping>
    <servlet-name>resources</servlet-name>
    <url-pattern>/adf/*</url-pattern>
  </servlet-mapping>


  <!-- Welcome Files -->
  <welcome-file-list>
    <welcome-file>index.html</welcome-file>
  </welcome-file-list>
  
</web-app>

7o. Implementei o codigo echo.jsp do guide do Item 4.

8o. O codigo echo.jsp do guide retorna :

HTTP Status 500 - 

--------------------------------------------------------------------------------

type Exception report

message 

description The server encountered an internal error () that prevented it from fulfilling this request.

exception 

org.apache.jasper.JasperException: An exception occurred processing JSP page /echoo.jsp at line 10

7:         <title>repeater </title> 
8:       </head>
9:       <body>
10:         <f:view>
11:           <h:form>
12:               <rich:panel header="Simple Echo">
13:                 <h:inputText size="50" value="#{bean.text}" > 


Stacktrace:
	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:505)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:416)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)


root cause 

java.lang.RuntimeException: Cannot find FacesContext
	javax.faces.webapp.UIComponentClassicTagBase.getFacesContext(UIComponentClassicTagBase.java:1796)
	javax.faces.webapp.UIComponentClassicTagBase.setJspId(UIComponentClassicTagBase.java:1613)
	org.apache.jsp.echoo_jsp._jspx_meth_f_005fview_005f0(echoo_jsp.java:108)
	org.apache.jsp.echoo_jsp._jspService(echoo_jsp.java:82)
	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:374)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

9o. Implementei tambem o exemplo do http://livedemo.exadel.com/richfaces-demo/richfaces/actionparam.jsf?c=actionparam
e este me retorna :

type Exception report

message 

description The server encountered an internal error () that prevented it from fulfilling this request.

exception 

org.apache.jasper.JasperException: /echo.jsp(9,58) #{..} is not allowed in template text
	org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:40)
	org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
	org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:102)
	org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:711)
	org.apache.jasper.compiler.Node$ELExpression.accept(Node.java:940)
	org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2343)
	org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2393)
	org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2399)
	org.apache.jasper.compiler.Node$Root.accept(Node.java:489)
	org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2343)
	org.apache.jasper.compiler.Validator.validate(Validator.java:1737)
	org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:165)
	org.apache.jasper.compiler.Compiler.compile(Compiler.java:314)
	org.apache.jasper.compiler.Compiler.compile(Compiler.java:294)
	org.apache.jasper.compiler.Compiler.compile(Compiler.java:281)
	org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)


note The full stack trace of the root cause is available in the Apache Tomcat/6.0.16 logs.

10o. Meu faces-config.xml

<?xml version="1.0"?>
<!--
    Licensed to the Apache Software Foundation (ASF) under one
    or more contributor license agreements.  See the NOTICE file
    distributed with this work for additional information
    regarding copyright ownership.  The ASF licenses this file
    to you under the Apache License, Version 2.0 (the
    "License"); you may not use this file except in compliance
    with the License.  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing,
    software distributed under the License is distributed on an
    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    KIND, either express or implied.  See the License for the
    specific language governing permissions and limitations
    under the License.
	   
-->

<faces-config xmlns="http://java.sun.com/xml/ns/javaee"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd"
  version="1.2">
  
  <application>
    <!-- Use the Trinidad RenderKit -->
    <default-render-kit-id>
      org.apache.myfaces.trinidad.core
    </default-render-kit-id>
  </application>

  <!-- Global preferences object that proxies to others -->
  <managed-bean>
    <managed-bean-name>helloWorldBacking</managed-bean-name>
    <managed-bean-class>
       org.apache.myfaces.trinidad.blank.HelloWorldBacking
    </managed-bean-class>
    <managed-bean-scope>
       request
    </managed-bean-scope>
  </managed-bean>
  
  
	<managed-bean>
        <managed-bean-name>bean</managed-bean-name>
        <managed-bean-class>demo.Bean</managed-bean-class>
        <managed-bean-scope>application</managed-bean-scope>
        <managed-property>
          <property-name>text</property-name>
          <value/>
        </managed-property>
      </managed-bean>
      
          
  <!-- navigation rules for index.jspx -->
  <navigation-rule>
    <from-view-id>/page1.jspx</from-view-id>
    <navigation-case>
      <from-outcome>success</from-outcome>
      <to-view-id>/page2.jspx</to-view-id>
    </navigation-case>
  </navigation-rule>
	
  <!-- navigation rules for page2.jspx -->
  <navigation-rule>
    <from-view-id>/page2.jspx</from-view-id>
    <navigation-case>
      <from-outcome>back</from-outcome>
      <to-view-id>/page1.jspx</to-view-id>
    </navigation-case>
  </navigation-rule>

</faces-config>

Alguem sabe o que estou fazendo de errado ? Ou entao um tutorial sobre este assunto ?

Obrigado.
Mario Oshiro.