[jboss-user] [JBoss Seam] - Seam 2.0.0.0GA + Maven2 doesn`t work...

w17chm4n do-not-reply at jboss.com
Fri Nov 9 07:20:50 EST 2007


First, this is how I did build my application with Seam 1.2.1.GA

Main pom.xml

  | <?xml version="1.0" encoding="UTF-8"?>
  | <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>com.blstream.inquisitor</groupId>
  |   <artifactId>Inquisitor</artifactId>
  |   <packaging>pom</packaging>
  |   <version>1.0-SNAPSHOT</version>
  |   <name>Inquisitor</name>
  |   <repositories>
  |     <repository>
  |       <id>JBossMaven2Repository</id>
  |       <name>JBoss Maven2 Repository</name>
  |       <url>http://repository.jboss.com/maven2</url>
  |     </repository>
  |   </repositories>
  |   <dependencyManagement>
  |     <dependencies>
  |       <dependency>
  | 	<groupId>jboss</groupId>
  | 	<artifactId>jboss-seam</artifactId>
  | 	<version>1.2.1.GA</version>
  |       </dependency>
  |     </dependencies>
  |   </dependencyManagement>
  |   <build>
  |     <plugins>
  |       <plugin>
  | 	<artifactId>maven-compiler-plugin</artifactId>
  | 	<configuration>
  | 	  <fileName>ear/target/Inquisitor.ear</fileName>
  | 	  <source>1.5</source>
  | 	  <target>1.5</target>
  | 	</configuration>
  |       </plugin>
  |     </plugins>
  |   </build>
  |   <modules>
  |     <module>webapp</module>
  |     <module>ejb3</module>
  |     <module>ear</module>
  |   </modules>
  | </project>
  | 

Ear

  | <?xml version="1.0"?><project>
  |     <parent>
  |         <artifactId>Inquisitor</artifactId>
  |         <groupId>com.blstream.inquisitor</groupId>
  |         <version>1.0-SNAPSHOT</version>
  |     </parent>
  |     <modelVersion>4.0.0</modelVersion>
  |     <groupId>com.blstream.inquisitor</groupId>
  |     <artifactId>ear</artifactId>
  |     <packaging>ear</packaging>
  |     <name>Inquisitor::${artifactId}</name>
  |     <version>${pom.parent.version}</version>
  |     <dependencies>
  |         <dependency>
  |             <groupId>junit</groupId>
  |             <artifactId>junit</artifactId>
  |             <version>3.8.1</version>
  |             <scope>test</scope>
  |         </dependency>
  |         <dependency>
  |             <groupId>com.blstream.inquisitor</groupId>
  |             <artifactId>ejb3</artifactId>
  |             <version>${pom.parent.version}</version>
  |             <type>ejb</type>
  |         </dependency>
  |         <dependency>
  |             <groupId>com.blstream.inquisitor</groupId>
  |             <artifactId>webapp</artifactId>
  |             <version>${pom.parent.version}</version>
  |             <type>war</type>
  |         </dependency>
  |     </dependencies>
  |     <build>
  |         <plugins>
  |             <plugin>
  |                 <artifactId>maven-ear-plugin</artifactId>
  |                 <configuration>
  |                     <modules>
  |                         <ejbModule>
  |                             <groupId>com.blstream.inquisitor</groupId>
  |                             <artifactId>ejb3</artifactId>
  |                         </ejbModule>
  |                         <javaModule>
  |                             <groupId>jboss</groupId>
  |                             <artifactId>jboss-seam</artifactId>
  |                             <includeInApplicationXml>true</includeInApplicationXml>
  |                         </javaModule>
  |                         <webModule>
  |                             <groupId>com.blstream.inquisitor</groupId>
  |                             <artifactId>webapp</artifactId>
  |                             <contextRoot>inquisitor</contextRoot>
  |                         </webModule>
  |                     </modules>
  |                 </configuration>
  |             </plugin>
  |         </plugins>
  |         <finalName>Inquisitor</finalName>
  |     </build>
  | </project>
  | 

War

  | <?xml version="1.0"?><project>
  |     <parent>
  |         <artifactId>Inquisitor</artifactId>
  |         <groupId>com.blstream.inquisitor</groupId>
  |         <version>1.0-SNAPSHOT</version>
  |     </parent>
  |     <modelVersion>4.0.0</modelVersion>
  |     <groupId>com.blstream.inquisitor</groupId>
  |     <artifactId>webapp</artifactId>
  |     <packaging>war</packaging>
  |     <name>Inquisitor::${artifactId}</name>
  |     <version>${pom.parent.version}</version>
  |     <build>
  |         <finalName>webapp</finalName>
  |     </build>
  |     <repositories>
  |         <repository>
  |             <id>JBossMaven2Repository</id>
  |             <name>JBoss Maven2 Repository</name>
  |             <url>http://repository.jboss.com/maven2</url>
  |         </repository>
  |     </repositories>
  |     <dependencies>
  |         <dependency>
  |             <groupId>junit</groupId>
  |             <artifactId>junit</artifactId>
  |             <version>3.8.1</version>
  |             <scope>test</scope>
  |         </dependency>
  |         <dependency>
  |             <groupId>jboss</groupId>
  |             <artifactId>jboss-seam-ui</artifactId>
  |             <version>1.2.1.GA</version>
  |         </dependency>
  |         <dependency>
  |             <groupId>jboss</groupId>
  |             <artifactId>jboss-seam-debug</artifactId>
  |             <version>1.2.1.GA</version>
  |         </dependency>
  |         <dependency>
  |             <groupId>com.sun.facelets</groupId>
  |             <artifactId>jsf-facelets</artifactId>
  |             <version>1.1.11</version>
  |         </dependency>
  |     </dependencies>
  | </project>
  | 

Ejb3 jar

  | <?xml version="1.0"?><project>
  |     <parent>
  |         <artifactId>Inquisitor</artifactId>
  |         <groupId>com.blstream.inquisitor</groupId>
  |         <version>1.0-SNAPSHOT</version>
  |     </parent>
  |     <modelVersion>4.0.0</modelVersion>
  |     <groupId>com.blstream.inquisitor</groupId>
  |     <artifactId>ejb3</artifactId>
  |     <packaging>ejb</packaging>
  |     <name>Inquisitor::${artifactId}</name>
  |     <version>${pom.parent.version}</version>
  |     <repositories>
  |         <repository>
  |             <id>JBossMaven2Repository</id>
  |             <name>JBoss Maven2 Repository</name>
  |             <url>http://repository.jboss.com/maven2</url>
  |         </repository>
  |     </repositories>
  |     <build>
  |         <finalName>ejb3</finalName>
  |     </build>
  |     <modules>
  |         <javaModule>jboss-seam-1.2.1.GA</javaModule>
  |     </modules>
  |     <dependencies>
  |         <dependency>
  |             <groupId>junit</groupId>
  |             <artifactId>junit</artifactId>
  |             <version>3.8.1</version>
  |             <scope>test</scope>
  |         </dependency>
  |         <dependency>
  |             <groupId>jboss</groupId>
  |             <artifactId>jboss-seam</artifactId>
  |         </dependency>
  |         <dependency>
  |             <!--<groupId>jboss</groupId>-->
  |             <groupId>org.jboss.javaee</groupId>
  |             <artifactId>jboss-ejb-api</artifactId>
  |             <!--<version>4.2.1.GA</version>-->
  |             <version>3.0.0.20070913080910</version>
  |         </dependency>
  |         <dependency>
  |             <groupId>javax.persistence</groupId>
  |             <artifactId>persistence-api</artifactId>
  |             <version>1.0</version>
  |         </dependency>
  |         <dependency>
  |             <groupId>org.hibernate</groupId>
  |             <artifactId>hibernate-validator</artifactId>
  |             <version>3.0.0.GA</version>
  |         </dependency>
  |     </dependencies>
  | </project>
  | 

So with pom`s setted as above I could easyly build and deploy my application. But the problem is when I want to migrate to Seam 2.0.0.GA. To do that I simply change versions and groupId for modules. New libs are downloaded and package is build, but it`s impossible to deploy it (I`m using JBoss 4.2.2).

The problem is that pom`s setted up for jboss-seam, jboss-seam-ui and jboss-seam-debug are hmmmm wrong. 

When building application with version 2.0.0.GA of Seam, maven is building ear which helds most of the libs but it also packs up the same libs into the war ! That makes it impossible to deploy - as far as I think. Maybe new pom`s work when building single war file, but not when trying to build an ear,

Oh and I have a question, why there are so many depencies in 2.0.0.GA ?

1.2.1.GA

  | <?xml version="1.0" encoding="UTF-8"?><project>
  |   <modelVersion>4.0.0</modelVersion>
  |   <groupId>jboss</groupId>
  |   <artifactId>jboss-seam</artifactId>
  |   <version>1.2.1.GA</version>
  | </project>
  | 

2.0.0.GA

  | <?xml version="1.0" encoding="UTF-8"?>
  | <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.jboss.seam</groupId>
  |   <artifactId>jboss-seam</artifactId>
  |   <parent>
  |     <groupId>org.jboss.seam</groupId>
  |     <artifactId>parent</artifactId>
  |     <version>2.0.0.GA</version>
  |   </parent>
  | 
  |   <!-- 
  |     * Dependencies marked optional are provide optional features of Seam, not necessarily included in JBoss AS
  |   -->
  | 
  |   <dependencies>
  |     <dependency>
  |       <groupId>org.hibernate</groupId>
  |       <artifactId>hibernate</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.hibernate</groupId>
  |       <artifactId>hibernate-annotations</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.hibernate</groupId>
  |       <artifactId>hibernate-validator</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  |     
  |     <dependency>
  |       <groupId>org.hibernate</groupId>
  |       <artifactId>hibernate-search</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  |     
  |     <dependency>
  |       <groupId>org.hibernate</groupId>
  |       <artifactId>hibernate-entitymanager</artifactId>
  |       <scope>runtime</scope>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>jboss</groupId>
  |       <artifactId>javassist</artifactId>
  |     </dependency>
  |     
  |     <dependency>
  |       <groupId>dom4j</groupId>
  |       <artifactId>dom4j</artifactId>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.portlet</groupId>
  |       <artifactId>portlet-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.servlet</groupId>
  |       <artifactId>servlet-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.mail</groupId>
  |       <artifactId>mail</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.xml.ws</groupId>
  |       <artifactId>jaxws-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  |     
  |     <dependency>
  |       <groupId>javax.jws</groupId>
  |       <artifactId>jsr181-api</artifactId>
  |       <scope>runtime</scope>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.faces</groupId>
  |       <artifactId>jsf-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.servlet.jsp</groupId>
  |       <artifactId>jsp-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.ejb</groupId>
  |       <artifactId>ejb-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>com.octo.captcha</groupId>
  |       <artifactId>jcaptcha-all</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.xml.soap</groupId>
  |       <artifactId>saaj-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.jms</groupId>
  |       <artifactId>jms</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.annotation</groupId>
  |       <artifactId>jsr250-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.transaction</groupId>
  |       <artifactId>jta</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>groovy</groupId>
  |       <artifactId>groovy-all</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>log4j</groupId>
  |       <artifactId>log4j</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.el</groupId>
  |       <artifactId>el-api</artifactId>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.persistence</groupId>
  |       <artifactId>persistence-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>antlr</groupId>
  |       <artifactId>antlr</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  |     
  |     <dependency>
  |       <groupId>org.apache.ant</groupId>
  |       <artifactId>ant-antlr</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>jboss</groupId>
  |       <artifactId>jboss-cache</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  |     
  |     <!-- This is actually a dep of jboss-cache, but it doesn't declare it -->
  |     <dependency>
  |       <groupId>jboss</groupId>
  |       <artifactId>jboss-system</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  |     
  |     <!-- This is actually a dep of jboss-cache, but it doesn't declare it -->
  |     <dependency>
  |       <groupId>jboss</groupId>
  |       <artifactId>jboss-jmx</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  |     
  |     <!-- This is actually a dep of jboss-cache, but it doesn't declare it -->
  |     <dependency>
  |       <groupId>jgroups</groupId>
  |       <artifactId>jgroups</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.buni.meldware</groupId>
  |       <artifactId>meldware-mailjmx</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.buni.meldware</groupId>
  |       <artifactId>meldware-mailapi</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.drools</groupId>
  |       <artifactId>drools-core</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.drools</groupId>
  |       <artifactId>drools-compiler</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <!-- Surefire can't cope with such a new version of testng, so we have to specify it
  |       here, otherwise ui build fails -->
  |     <dependency>
  |       <groupId>org.testng</groupId>
  |       <artifactId>testng</artifactId>
  |       <version>5.6</version>
  |       <optional>true</optional>
  |       <exclusions>
  |         <exclusion>
  |           <groupId>junit</groupId>
  |           <artifactId>junit</artifactId>
  |         </exclusion>
  |       </exclusions>
  |     </dependency>
  |     
  |     <dependency>
  |       <groupId>org.dbunit</groupId>
  |       <artifactId>dbunit</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.jbpm</groupId>
  |       <artifactId>jbpm-jpdl</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.jboss.seam</groupId>
  |       <artifactId>jboss-el</artifactId>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.jboss.embedded</groupId>
  |       <artifactId>jboss-embedded-api</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>quartz</groupId>
  |       <artifactId>quartz</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>javax.faces</groupId>
  |       <artifactId>jsf-impl</artifactId>
  |       <optional>true</optional>
  |     </dependency>
  | 
  |     <dependency>
  |       <groupId>org.tuckey</groupId>
  |       <artifactId>urlrewritefilter</artifactId>
  |       <optional>true</optional>
  |       <scope>runtime</scope>
  |     </dependency>
  | 
  |   </dependencies>
  | 
  | </project>
  | 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4103218#4103218

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4103218



More information about the jboss-user mailing list