paulwong

一个使用GUZZ+SPRING的MAVEN项目POM文件

有依赖的包管理,可以部署到TOMCAT 6.X,可以使用JETTY作开发测试,可以生成站点,作CHECK STYLE,PMD代码检查,代码覆盖率,生成JAVA DOC。

<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.paul</groupId>
  
<artifactId>guzz</artifactId>
  
<packaging>war</packaging>
  
<version>0.0.1-SNAPSHOT</version>
  
<name>guzz Maven Webapp</name>
  
<url>http://maven.apache.org</url>

    
<properties>
        
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        
<lib.spring.version>3.0.5.RELEASE</lib.spring.version>
        
        
<!-- Framework dependency versions -->
        
<cargo.version>1.1.3</cargo.version>
        
        
<!-- Cargo settings -->
        
<cargo.container>tomcat6x</cargo.container>
        
<cargo.container.home>E:\PAUL\DOWNLOAD\apache-tomcat-6.0.32</cargo.container.home>
        
<cargo.container.url>http://archive.apache.org/dist/tomcat/tomcat-6/v6.0.29/bin/apache-tomcat-6.0.29.zip</cargo.container.url>
        
<cargo.host>localhost</cargo.host>
        
<cargo.port>25888</cargo.port>
        
<cargo.wait>false</cargo.wait>
    
</properties>
    
  
<dependencies>
        
<dependency>
            
<groupId>org.guzz</groupId>
            
<artifactId>guzz</artifactId>
            
<version>1.2.9</version>
        
</dependency>
        
<dependency>
            
<groupId>c3p0</groupId>
            
<artifactId>c3p0</artifactId>
            
<version>0.9.1</version>
        
</dependency>
        
<dependency>
            
<groupId>commons-fileupload</groupId>
            
<artifactId>commons-fileupload</artifactId>
            
<version>1.2.2</version>
        
</dependency>
        
<dependency>
            
<groupId>commons-dbcp</groupId>
            
<artifactId>commons-dbcp</artifactId>
            
<version>1.2</version>
        
</dependency>
        
<dependency>
            
<groupId>junit</groupId>
            
<artifactId>junit</artifactId>
            
<version>3.8.1</version>
            
<scope>test</scope>
        
</dependency>
        
<dependency>
            
<groupId>javax.servlet</groupId>
            
<artifactId>servlet-api</artifactId>
            
<version>2.5</version>
            
<scope>provided</scope>
        
</dependency>
        
<dependency>
            
<groupId>javax.servlet</groupId>
            
<artifactId>jstl</artifactId>
            
<version>1.2</version>
        
</dependency>
        
<dependency>
            
<groupId>javax.servlet.jsp</groupId>
            
<artifactId>jsp-api</artifactId>
            
<version>2.1</version>
            
<scope>provided</scope>
        
</dependency>
        
<dependency>
            
<groupId>org.springframework</groupId>
            
<artifactId>spring-core</artifactId>
            
<version>${lib.spring.version}</version>
        
</dependency>
        
<dependency>
            
<groupId>org.springframework</groupId>
            
<artifactId>spring-beans</artifactId>
            
<version>${lib.spring.version}</version>
        
</dependency>
        
<dependency>
            
<groupId>org.springframework</groupId>
            
<artifactId>spring-context</artifactId>
            
<version>${lib.spring.version}</version>
        
</dependency>
        
<dependency>
            
<groupId>hessian</groupId>
            
<artifactId>hessian</artifactId>
            
<version>3.0.1</version>
        
</dependency>
        
<dependency>
            
<groupId>mysql</groupId>
            
<artifactId>mysql-connector-java</artifactId>
            
<version>5.1.16</version>
            
<scope>runtime</scope>
        
</dependency>
        
<dependency>
            
<groupId>org.springframework</groupId>
            
<artifactId>spring-web</artifactId>
            
<version>${lib.spring.version}</version>
        
</dependency>
        
<!-- <dependency> <groupId>org.phprpc</groupId> <artifactId>phprpc-client</artifactId> 
            <version>1.0</version> <scope>system</scope> <systemPath>${project.build.localLib}phprpc_client.jar</systemPath> 
            </dependency> <dependency> <groupId>com.oracle</groupId> <artifactId>ojdbc14</artifactId> 
            <version>10.2.0.1.0</version> <scope>system</scope> <systemPath>${project.build.localLib}ojdbc14.jar</systemPath> 
            </dependency> 
-->
        
<dependency>
            
<groupId>com.h2database</groupId>
            
<artifactId>h2</artifactId>
            
<version>1.3.156</version>
            
<scope>test</scope>
        
</dependency>
        
<dependency>
            
<groupId>org.springframework</groupId>
            
<artifactId>spring-webmvc</artifactId>
            
<version>${lib.spring.version}</version>
            
<scope>compile</scope>
        
</dependency>
    
</dependencies>
  
    
    
<build>
        
<finalName>guzz</finalName>
        
<plugins>
            
<plugin>
                
<groupId>org.codehaus.cargo</groupId>
                
<artifactId>cargo-maven2-plugin</artifactId>
                
<version>${cargo.version}</version>
                
<configuration>

                    
<!-- Container configuration -->
                    
<container>
                        
<wait>${cargo.wait}</wait>
                        
<containerId>${cargo.container}</containerId>
                        
<home>${cargo.container.home}</home>
                        
<!-- Instead of downloading the container, you can also reuse an existing 
                            <zipUrlInstaller> <url>http://archive.apache.org/dist/tomcat/tomcat-6/v6.0.32/bin/apache-tomcat-6.0.32.zip</url> 
                            </zipUrlInstaller> installation by settings its directory: <home>c:/apps/tomcat-6.0.32</home> 
-->
                        
<output>${project.build.directory}/tomcat6x/container.log</output>
                        
<append>false</append>
                        
<log>${project.build.directory}/tomcat6x/cargo.log</log>
                    
</container>

                    
<!-- Configuration to use with the container or the deployer -->
                    
<configuration>
                        
<type>existing</type>
                        
<home>${cargo.container.home}</home>
                        
<properties>
                            
<cargo.servlet.port>8080</cargo.servlet.port>
                            
<cargo.logging>high</cargo.logging>
                        
</properties>

                    
</configuration>
                    
                
</configuration>
            
</plugin>
            
<plugin>
                
<groupId>org.mortbay.jetty</groupId>
                
<artifactId>jetty-maven-plugin</artifactId>
                
<version>8.0.4.v20111024</version>
                
<!-- 
                <artifactId>maven-jetty-plugin</artifactId>
                <version>6.1.26</version>
                
-->
                
<configuration>
                    
<contextPath>/</contextPath>
                    
<scanIntervalSeconds>3</scanIntervalSeconds>
                    
<scanTargetPatterns>
                        
<scanTargetPattern>
                            
<directory>src/main/webapp/WEB-INF</directory>
                            
<excludes>
                                
<exclude>**/*.jsp</exclude>
                            
</excludes>
                            
<includes>
                                
<include>**/*.properties</include>
                                
<include>**/*.xml</include>
                            
</includes>
                        
</scanTargetPattern>
                    
</scanTargetPatterns>
                
</configuration>
            
</plugin>
            
<plugin>
                
<groupId>org.apache.maven.plugins</groupId>
                
<artifactId>maven-site-plugin</artifactId>
                
<version>3.0</version>
            
</plugin>
        
</plugins>
        
<!-- 如果SRC中含有非JAVA文件,则需要定义RESOURCE -->
        
<resources>
            
<resource>
                
<directory>src/main/java</directory>
                
<includes>
                    
<include>**/*.xml</include>
                
</includes>
            
</resource>
            
<resource>
                
<directory>src/main/resources</directory>
                
<filtering>false</filtering>
            
</resource>
        
</resources>
    
</build>
    
<reporting>
        
<plugins>
            
<plugin>
                
<groupId>org.apache.maven.plugins</groupId>
                
<artifactId>maven-checkstyle-plugin</artifactId>
                
<version>2.8</version>
            
</plugin>
            
<plugin>
                
<groupId>org.apache.maven.plugins</groupId>
                
<artifactId>maven-jxr-plugin</artifactId>
                
<version>2.3</version>
            
</plugin>
            
<plugin>
                
<groupId>org.apache.maven.plugins</groupId>
                
<artifactId>maven-javadoc-plugin</artifactId>
                
<version>2.8</version>
            
</plugin>
            
<plugin>
                
<groupId>org.apache.maven.plugins</groupId>
                
<artifactId>maven-pmd-plugin</artifactId>
                
<version>2.6</version>
            
</plugin>
            
<plugin>
                
<groupId>org.codehaus.mojo</groupId>
                
<artifactId>cobertura-maven-plugin</artifactId>
                
<version>2.5.1</version>
            
</plugin>
        
</plugins>
    
</reporting>
  
    
<dependencyManagement>
        
<dependencies>
        
</dependencies>
    
</dependencyManagement>
</project>

posted on 2011-11-30 16:18 paulwong 阅读(1486) 评论(2)  编辑  收藏 所属分类: MAVEN

Feedback

# re: 一个使用GUZZ+SPRING的MAVEN项目POM文件 2012-11-22 10:34 mocos

能给个spring3.1+guzz的例子吗
w123dog@gmail.com  回复  更多评论   

# re: 一个使用GUZZ+SPRING的MAVEN项目POM文件 2012-11-23 13:05 paulwong

@mocos
上面那个就是了.  回复  更多评论   



只有注册用户登录后才能发表评论。


网站导航: