1 Reply Latest reply on Jan 8, 2010 3:17 PM by Steven Boscarine

    Weld, Tomcat 6 and JSF API Issue

    Ashley Westwell Newbie

      Hey All


      I have taken the sample from http://info.rmatics.org/2009/10/17/jsf2tutorial0/ to get Weld, Tomcat 6.0.20 and JSF 2 working together. Everything works fine but if I try to update JSF API and IMPL from 2.0.0-RC to 2.0.2-FCS it no longer evaluates the expression.


      Here is the project pom.xml that works fine


      <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
          <modelVersion>4.0.0</modelVersion>
          <groupId>org.bogus</groupId>
          <artifactId>helloworld</artifactId>
          <packaging>war</packaging>
          <version>0.0.1-SNAPSHOT</version>
          <name>JSF 2.0 Tutorial</name>
          <repositories>
              <repository>
                  <id>repository.jboss.org</id>
                  <name>JBoss Repository</name>
                  <url>http://repository.jboss.org/maven2</url>
                  <releases>
                      <enabled>true</enabled>
                  </releases>
                  <snapshots>
                      <enabled>false</enabled>
                  </snapshots>
              </repository>
          </repositories>
          <dependencies>
              <!-- Common -->
              <dependency>
                  <groupId>javax.enterprise</groupId>
                  <artifactId>cdi-api</artifactId>
                  <scope>provided</scope>
                  <version>1.0</version>
              </dependency>
              <dependency>
                  <groupId>javax.annotation</groupId>
                  <artifactId>jsr250-api</artifactId>
                  <version>1.0</version>
              </dependency>
              <dependency>
                  <groupId>javax.faces</groupId>
                  <artifactId>jsf-api</artifactId>
                  <version>2.0.0-RC</version>
              </dependency>
              <dependency>
                  <groupId>javax.faces</groupId>
                  <artifactId>jsf-impl</artifactId>
                  <version>2.0.0-RC</version>
                  <scope>runtime</scope>
              </dependency>
              <dependency>
                  <groupId>javax.servlet</groupId>
                  <artifactId>jstl</artifactId>
                  <version>1.2</version>
                  <scope>runtime</scope>
              </dependency>
              <dependency>
                  <groupId>org.jboss.weld.servlet</groupId>
                  <artifactId>weld-servlet</artifactId>
                  <version>1.0.0-CR2</version>
                  <scope>runtime</scope>
              </dependency>
              <dependency>
                  <groupId>org.glassfish.web</groupId>
                  <artifactId>el-impl</artifactId>
                  <scope>runtime</scope>
                  <version>2.1.2-b04</version>
                  <exclusions>
                      <exclusion>
                          <groupId>javax.el</groupId>
                          <artifactId>el-api</artifactId>
                      </exclusion>
                  </exclusions>
              </dependency>
          </dependencies>
          <build>
              <finalName>jsf2</finalName>
              <plugins>
                  <!-- Compiler plugin enforces Java 1.6 -->
                  <plugin>
                      <groupId>org.apache.maven.plugins</groupId>
                      <artifactId>maven-compiler-plugin</artifactId>
                      <configuration>
                          <source>1.6</source>
                          <target>1.6</target>
                      </configuration>
                  </plugin>
                  <!-- Eclipse plugin enforces download of source and JavaDoc jars -->
                  <plugin>
                      <groupId>org.apache.maven.plugins</groupId>
                      <artifactId>maven-eclipse-plugin</artifactId>
                      <configuration>
                          <wtpversion>2.0</wtpversion>
                          <downloadSources>true</downloadSources>
                          <downloadJavadocs>true</downloadJavadocs>
                      </configuration>
                  </plugin>
              </plugins>
          </build>
      </project>



      If I change the dependencies to the following it stops evaluation the expression any help would be greatly appreciated




              <dependency>
                  <groupId>javax.faces</groupId>
                  <artifactId>jsf-api</artifactId>
                  <version>2.0.2-FCS</version>
              </dependency>
              <dependency>
                  <groupId>javax.faces</groupId>
                  <artifactId>jsf-impl</artifactId>
                  <version>2.0.2-FCS</version>
                  <scope>runtime</scope>
              </dependency>





      Thanks


      -Ashley