03.基于IDEA+Spring+Maven搭建测试项目--常用dependency

<!--常用的依赖配置-->
<!--未展示完整的pom.xml文件内容-->
<properties>
        <java.version>1.8</java.version>
        <java.encoding>UTF-8</java.encoding>
        <org.springframework.version>4.2.4.RELEASE</org.springframework.version>
        <org.mybatis.version>3.3.0</org.mybatis.version>
        <org.mybatis.spring.version>1.2.0</org.mybatis.spring.version>
        <c3p0.version>0.9.5-pre10</c3p0.version>
        <dubbo.version>2.5.3</dubbo.version>
        <fastjson.version>1.1.27</fastjson.version>
        <commons.dbcp.version>1.4</commons.dbcp.version>
        <slf4j.version>1.7.9</slf4j.version>
        <logback.version>1.1.1</logback.version>
        <jdbcdslog.version>1.0.6.2</jdbcdslog.version>
        <lombok.version>1.16.6</lombok.version>
        <junit.version>4.11</junit.version>
        <cglib.version>2.2.2</cglib.version>
        <zookeeper.version>3.4.6</zookeeper.version>
        <baofoo-commons.version>1.0-SNAPSHOT</baofoo-commons.version>
        <oval.version>1.81</oval.version>
        <mysql.version>5.1.34</mysql.version>
        <org.slf4j.version>1.7.6</org.slf4j.version>
        <log4j.version>1.2.9</log4j.version>
        <commons-lang3.version>3.4</commons-lang3.version>
        <joda.time.version>2.9.1</joda.time.version>
        <dfs-client.version>1.2.0</dfs-client.version>
        <zkclient.version>0.1</zkclient.version>

        <maven-deploy-plugin.version>2.7</maven-deploy-plugin.version>
        <maven-source-plugin>2.1</maven-source-plugin>
        <maven-compiler-plugin>3.1</maven-compiler-plugin>
        <maven-dependency-plugin>2.8</maven-dependency-plugin>
        <maven-antrun-plugin>1.8</maven-antrun-plugin>
        <maven-surefire-plugin>2.3</maven-surefire-plugin>
        <maven-war-plugin>2.6</maven-war-plugin>
    </properties>
    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>${junit.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-web</artifactId>
            <version>${org.springframework.version}</version>
            <exclusions>
                <exclusion>
                    <artifactId>commons-logging</artifactId>
                    <groupId>commons-logging</groupId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-webmvc</artifactId>
            <version>${org.springframework.version}</version>
            <exclusions>
                <exclusion>
                    <artifactId>commons-logging</artifactId>
                    <groupId>commons-logging</groupId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-context</artifactId>
            <version>${org.springframework.version}</version>
            <exclusions>
                <exclusion>
                    <artifactId>commons-logging</artifactId>
                    <groupId>commons-logging</groupId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-jdbc</artifactId>
            <version>${org.springframework.version}</version>
            <exclusions>
                <exclusion>
                    <artifactId>commons-logging</artifactId>
                    <groupId>commons-logging</groupId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-tx</artifactId>
            <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-context-support</artifactId>
            <version>${org.springframework.version}</version>
        </dependency>
        <!-- alibaba dubbo -->
        <dependency>
            <groupId>com.alibaba</groupId>
            <artifactId>dubbo</artifactId>
            <version>${dubbo.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>log4j</groupId>
                    <artifactId>log4j</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>commons-logging</groupId>
                    <artifactId>commons-logging</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>org.springframework</groupId>
                    <artifactId>spring</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>com.alibaba</groupId>
            <artifactId>fastjson</artifactId>
            <version>${fastjson.version}</version>
        </dependency>
        <dependency>
            <groupId>com.github.sgroschupf</groupId>
            <artifactId>zkclient</artifactId>
            <version>${zkclient.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>org.apache.zookeeper</groupId>
                    <artifactId>zookeeper</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>log4j</groupId>
                    <artifactId>log4j</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>junit</groupId>
                    <artifactId>junit</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <!-- slf4j -->
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
            <version>${logback.version}</version>
        </dependency>
        <!-- mysql-->
        <dependency>
            <groupId>mysql</groupId>
            <artifactId>mysql-connector-java</artifactId>
            <version>${mysql.version}</version>
        </dependency>
        <!-- c3p0 -->
        <dependency>
            <groupId>com.mchange</groupId>
            <artifactId>c3p0</artifactId>
            <version>${c3p0.version}</version>
        </dependency>
        <!-- mybatis -->
        <dependency>
            <groupId>org.mybatis</groupId>
            <artifactId>mybatis</artifactId>
            <version>${org.mybatis.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>org.slf4j</groupId>
                    <artifactId>slf4j-log4j12</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.mybatis</groupId>
            <artifactId>mybatis-spring</artifactId>
            <version>${org.mybatis.spring.version}</version>
        </dependency>
        <!-- cglib -->
        <dependency>
            <groupId>cglib</groupId>
            <artifactId>cglib-nodep</artifactId>
            <version>${cglib.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.zookeeper</groupId>
            <artifactId>zookeeper</artifactId>
            <version>${zookeeper.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>log4j</groupId>
                    <artifactId>log4j</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <!-- slf4j -->
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>jcl-over-slf4j</artifactId>
            <!-- use this to transfer spring‘s log to slf4j -->
            <version>${slf4j.version}</version>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>${slf4j.version}</version>
        </dependency>
        <!--  lombok -->
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <version>${lombok.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-test</artifactId>
            <version>${org.springframework.version}</version>
            <scope>test</scope>
        </dependency>
        <!--  validate -->
        <dependency>
            <groupId>net.sf.oval</groupId>
            <artifactId>oval</artifactId>
            <version>${oval.version}</version>
        </dependency>
        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <version>${log4j.version}</version>
        </dependency>
        <!-- commons utils -->
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
            <version>${commons-lang3.version}</version>
        </dependency>
        <!--  joda-time -->
        <dependency>
            <groupId>joda-time</groupId>
            <artifactId>joda-time</artifactId>
            <version>${joda.time.version}</version>
        </dependency>
    </dependencies>

  

原文地址:https://www.cnblogs.com/xiuxingzhe/p/9250786.html

时间: 2024-10-01 20:56:28

03.基于IDEA+Spring+Maven搭建测试项目--常用dependency的相关文章

02.基于IDEA+Spring+Maven搭建测试项目--Maven的配置文件settings.xml

1 <?xml version="1.0" encoding="UTF-8"?> 2 <settings xmlns="http://maven.apache.org/SETTINGS/4.0.0" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 4 xsi:schemaLocation="http://maven.apache.org

04.基于IDEA+Spring+Maven搭建测试项目--配置web.xml

1 <!DOCTYPE web-app PUBLIC 2 "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" 3 "http://java.sun.com/dtd/web-app_2_3.dtd" > 4 5 <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 6 xmlns="htt

02.基于IDEA+Spring+Maven搭建测试项目--配置logback.xml

1 <?xml version="1.0" encoding="UTF-8"?> 2 <configuration> 3 <!-- 控制台日志打印,测试环境和调试使用,发布生产需注释 --> 4 <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender"> 5 <encoder charset=&q

02.基于IDEA+Spring+Maven搭建测试项目--配置dubbo-consumer.xml

1 <?xml version="1.0" encoding="UTF-8"?> 2 <beans xmlns="http://www.springframework.org/schema/beans" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 4 xmlns:dubbo="http://code.alibabatech.com/

04.基于IDEA+Spring+Maven搭建测试项目--配置application-context.xml

1 <?xml version="1.0" encoding="UTF-8"?> 2 <beans xmlns="http://www.springframework.org/schema/beans" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 4 xmlns:context="http://www.springframework

基于Spring+IDEA+Maven搭建测试项目

一.背景介绍 1.1公司相关技术 Git:是一款免费的开源的分布式版本控制系统,用于敏捷高效地处理任何或小或大的项目,方便多人集成开发 Maven:是基于项目对象模型(POM),可以通过一小段描述信息来管理项目的构建,报告和文档的软件项目管理工具,同时还提供了高级项目管理工具 Jira:是Atlassian公司出品的项目与事务跟踪工具,被广泛应用于缺陷跟踪.客户服务.需求收集.流程审批.任务跟踪.项目跟踪和敏捷管理等工作领域 Dubbo:是阿里巴巴公司一个开源的分布式服务框架,致力于提供高性能和

Maven 搭建 SSM 项目 (oracle)

简单谈一下maven搭建 ssm 项目 (使用数据库oracle,比 mysql 难,所以这里谈一下) 在创建maven 的web项目时,常常会缺了main/java , main/test 两个文件夹. 解决方法: ① : 在项目上右键选择properties,然后点击java build path,在Librarys下,编辑JRE System Library,选择workspace default jre就可以了. (推荐使用这种) ② :手动创建 目录.切换视图采用Navigator视图

如何使用maven搭建web项目

博客园注册了有二十多天了,还没有写过博客,今天就发一篇,也便于后面查找笔记. 我个人已经做了几年的java web开发了,由于所在的公司是业务型公司,用的都是一些老旧的稳定技术,很少接触到稍微新点的内容, 经过几年的不进则退,自己的技术能力已经开始慢慢的被时代潮流淘汰.为了在大浪淘沙中能生存下来,自己要好好加油,从基本内容开始,稳步沉淀,更新自己的技术库. 不求一口吃个大胖子,只求每天进步一点点. 废话不多说,言归正传.如何使用maven搭建web项目呢? 第一步:首先创建一个maven项目 创

springmvc+maven搭建web项目之二 通过另一种方式配置spring

1.创建maven web项目 2. 配置pom.xml <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