当前位置: 首页 > news >正文

maven - pom.xml 聚合(父)工程 基本内容演示

企业开发中所用到的基本jar包以及插件都已在此

可以自己根据实际情况酌情增减

 

  1 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  2     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  3     <modelVersion>4.0.0</modelVersion>
  4     <groupId>com.lee</groupId>
  5     <artifactId>lee-parent</artifactId>
  6     <version>0.0.1-SNAPSHOT</version>
  7     <packaging>pom</packaging>
  8 
  9     <!-- 集中定义依赖版本号 -->
 10     <properties>
 11         <junit.version>4.12</junit.version>
 12         <spring.version>4.1.3.RELEASE</spring.version>
 13         <mybatis.version>3.2.8</mybatis.version>
 14         <mybatis.spring.version>1.2.2</mybatis.spring.version>
 15         <mybatis.paginator.version>1.2.15</mybatis.paginator.version>
 16         <mysql.version>5.1.32</mysql.version>
 17         <slf4j.version>1.6.4</slf4j.version>
 18         <jackson.version>2.4.2</jackson.version>
 19         <!-- 连接池 阿里巴巴数据源 全世界最牛逼的data source 没有之一 -->
 20         <druid.version>1.0.9</druid.version>
 21         <httpclient.version>4.3.5</httpclient.version>
 22         <jstl.version>1.2</jstl.version>
 23         <servlet-api.version>2.5</servlet-api.version>
 24         <jsp-api.version>2.0</jsp-api.version>
 25         <joda-time.version>2.5</joda-time.version>
 26         <commons-lang3.version>3.3.2</commons-lang3.version>
 27         <commons-io.version>1.3.2</commons-io.version>
 28         <commons-net.version>3.3</commons-net.version>
 29         <pagehelper.version>3.4.2-fix</pagehelper.version>
 30         <jsqlparser.version>0.9.1</jsqlparser.version>
 31         <commons-fileupload.version>1.3.1</commons-fileupload.version>
 32         <jedis.version>2.7.2</jedis.version>
 33         <solrj.version>4.10.3</solrj.version>
 34     </properties>
 35 
 36     <!-- 只定义依赖的版本,不会实际依赖 -->
 37     <dependencyManagement>
 38         <dependencies>
 39             <!-- 时间操作组件 -->
 40             <dependency>
 41                 <groupId>joda-time</groupId>
 42                 <artifactId>joda-time</artifactId>
 43                 <version>${joda-time.version}</version>
 44             </dependency>
 45             <!-- Apache工具组件 -->
 46             <dependency>
 47                 <groupId>org.apache.commons</groupId>
 48                 <artifactId>commons-lang3</artifactId>
 49                 <version>${commons-lang3.version}</version>
 50             </dependency>
 51             <dependency>
 52                 <groupId>org.apache.commons</groupId>
 53                 <artifactId>commons-io</artifactId>
 54                 <version>${commons-io.version}</version>
 55             </dependency>
 56             <dependency>
 57                 <groupId>commons-net</groupId>
 58                 <artifactId>commons-net</artifactId>
 59                 <version>${commons-net.version}</version>
 60             </dependency>
 61             <!-- Jackson Json处理工具包 -->
 62             <dependency>
 63                 <groupId>com.fasterxml.jackson.core</groupId>
 64                 <artifactId>jackson-databind</artifactId>
 65                 <version>${jackson.version}</version>
 66             </dependency>
 67             <!-- httpclient -->
 68             <dependency>
 69                 <groupId>org.apache.httpcomponents</groupId>
 70                 <artifactId>httpclient</artifactId>
 71                 <version>${httpclient.version}</version>
 72             </dependency>
 73             <!-- 单元测试 -->
 74             <dependency>
 75                 <groupId>junit</groupId>
 76                 <artifactId>junit</artifactId>
 77                 <version>${junit.version}</version>
 78                 <scope>test</scope>
 79             </dependency>
 80             <!-- 日志处理 -->
 81             <dependency>
 82                 <groupId>org.slf4j</groupId>
 83                 <artifactId>slf4j-log4j12</artifactId>
 84                 <version>${slf4j.version}</version>
 85             </dependency>
 86             <!-- Mybatis -->
 87             <dependency>
 88                 <groupId>org.mybatis</groupId>
 89                 <artifactId>mybatis</artifactId>
 90                 <version>${mybatis.version}</version>
 91             </dependency>
 92             <dependency>
 93                 <groupId>org.mybatis</groupId>
 94                 <artifactId>mybatis-spring</artifactId>
 95                 <version>${mybatis.spring.version}</version>
 96             </dependency>
 97             <dependency>
 98                 <groupId>com.github.miemiedev</groupId>
 99                 <artifactId>mybatis-paginator</artifactId>
100                 <version>${mybatis.paginator.version}</version>
101             </dependency>
102             <dependency>
103                 <groupId>com.github.pagehelper</groupId>
104                 <artifactId>pagehelper</artifactId>
105                 <version>${pagehelper.version}</version>
106             </dependency>
107             <!-- MySql -->
108             <dependency>
109                 <groupId>mysql</groupId>
110                 <artifactId>mysql-connector-java</artifactId>
111                 <version>${mysql.version}</version>
112             </dependency>
113             <!-- 连接池 阿里巴巴数据源 全世界最牛逼的data source 没有之一 -->
114             <dependency>
115                 <groupId>com.alibaba</groupId>
116                 <artifactId>druid</artifactId>
117                 <version>${druid.version}</version>
118             </dependency>
119             <!-- Spring -->
120             <dependency>
121                 <groupId>org.springframework</groupId>
122                 <artifactId>spring-context</artifactId>
123                 <version>${spring.version}</version>
124             </dependency>
125             <dependency>
126                 <groupId>org.springframework</groupId>
127                 <artifactId>spring-beans</artifactId>
128                 <version>${spring.version}</version>
129             </dependency>
130             <dependency>
131                 <groupId>org.springframework</groupId>
132                 <artifactId>spring-webmvc</artifactId>
133                 <version>${spring.version}</version>
134             </dependency>
135             <dependency>
136                 <groupId>org.springframework</groupId>
137                 <artifactId>spring-jdbc</artifactId>
138                 <version>${spring.version}</version>
139             </dependency>
140             <dependency>
141                 <groupId>org.springframework</groupId>
142                 <artifactId>spring-aspects</artifactId>
143                 <version>${spring.version}</version>
144             </dependency>
145             <!-- JSP相关 -->
146             <dependency>
147                 <groupId>jstl</groupId>
148                 <artifactId>jstl</artifactId>
149                 <version>${jstl.version}</version>
150             </dependency>
151             <dependency>
152                 <groupId>javax.servlet</groupId>
153                 <artifactId>servlet-api</artifactId>
154                 <version>${servlet-api.version}</version>
155                 <scope>provided</scope>
156             </dependency>
157             <dependency>
158                 <groupId>javax.servlet</groupId>
159                 <artifactId>jsp-api</artifactId>
160                 <version>${jsp-api.version}</version>
161                 <scope>provided</scope>
162             </dependency>
163             <!-- 文件上传组件 -->
164             <dependency>
165                 <groupId>commons-fileupload</groupId>
166                 <artifactId>commons-fileupload</artifactId>
167                 <version>${commons-fileupload.version}</version>
168             </dependency>
169             <!-- Redis客户端 -->
170             <dependency>
171                 <groupId>redis.clients</groupId>
172                 <artifactId>jedis</artifactId>
173                 <version>${jedis.version}</version>
174             </dependency>
175             <!-- solr客户端 -->
176             <dependency>
177                 <groupId>org.apache.solr</groupId>
178                 <artifactId>solr-solrj</artifactId>
179                 <version>${solrj.version}</version>
180             </dependency>
181         </dependencies>
182     </dependencyManagement>
183 
184     <build>
185         <finalName>${project.artifactId}</finalName>
186         <plugins>
187             <!-- 资源文件拷贝插件 -->
188             <plugin>
189                 <groupId>org.apache.maven.plugins</groupId>
190                 <artifactId>maven-resources-plugin</artifactId>
191                 <version>2.7</version>
192                 <configuration>
193                     <encoding>UTF-8</encoding>
194                 </configuration>
195             </plugin>
196             <!-- java编译插件 -->
197             <plugin>
198                 <groupId>org.apache.maven.plugins</groupId>
199                 <artifactId>maven-compiler-plugin</artifactId>
200                 <version>3.2</version>
201                 <configuration>
202                     <source>1.7</source>
203                     <target>1.7</target>
204                     <encoding>UTF-8</encoding>
205                 </configuration>
206             </plugin>
207         </plugins>
208         <pluginManagement>
209             <plugins>
210                 <!-- 配置Tomcat插件 -->
211                 <plugin>
212                     <groupId>org.apache.tomcat.maven</groupId>
213                     <artifactId>tomcat7-maven-plugin</artifactId>
214                     <version>2.2</version>
215                 </plugin>
216             </plugins>
217         </pluginManagement>
218     </build>
219 
220 </project>

 

相关文章:

  • service
  • 波特率时钟
  • HBase的一些关于CRUD方法
  • 自动化测试基础篇--Selenium单选框(Radio)复选框(CheckBox)
  • 基于图论的立体匹配方法研究----绪论
  • rails migration 增加索引
  • len(),range()函数
  • 长城电脑整体解决方案护航智慧城市安全
  • Java语法基础--运算
  • 问题010:在Java中,什么是常量,什么是变量?
  • 算法(四)--------动态规划问题
  • Mock Server 入门
  • 如何判断c语言的变量类型
  • paper 58 :机器视觉学习笔记(1)——OpenCV配置
  • Spring session redis ERR unknown command 'CONFIG'
  • [译]前端离线指南(上)
  • 【162天】黑马程序员27天视频学习笔记【Day02-上】
  • Android 架构优化~MVP 架构改造
  • JavaScript 奇技淫巧
  • Lucene解析 - 基本概念
  • pdf文件如何在线转换为jpg图片
  • Redis 懒删除(lazy free)简史
  • Shell编程
  • Solarized Scheme
  • vagrant 添加本地 box 安装 laravel homestead
  • vuex 笔记整理
  • 订阅Forge Viewer所有的事件
  • 更好理解的面向对象的Javascript 1 —— 动态类型和多态
  • 聊一聊前端的监控
  • 浏览器缓存机制分析
  • 漫谈开发设计中的一些“原则”及“设计哲学”
  • 如何合理的规划jvm性能调优
  • ​Base64转换成图片,android studio build乱码,找不到okio.ByteString接腾讯人脸识别
  • (C#)Windows Shell 外壳编程系列9 - QueryInfo 扩展提示
  • (Redis使用系列) SpringBoot 中对应2.0.x版本的Redis配置 一
  • (TOJ2804)Even? Odd?
  • (ZT)北大教授朱青生给学生的一封信:大学,更是一个科学的保证
  • (汇总)os模块以及shutil模块对文件的操作
  • (译) 函数式 JS #1:简介
  • (转)ABI是什么
  • .Net 4.0并行库实用性演练
  • .net CHARTING图表控件下载地址
  • .net redis定时_一场由fork引发的超时,让我们重新探讨了Redis的抖动问题
  • .net websocket 获取http登录的用户_如何解密浏览器的登录密码?获取浏览器内用户信息?...
  • .NET 服务 ServiceController
  • .NET/C# 的字符串暂存池
  • .NET/C# 如何获取当前进程的 CPU 和内存占用?如何获取全局 CPU 和内存占用?
  • .secret勒索病毒数据恢复|金蝶、用友、管家婆、OA、速达、ERP等软件数据库恢复
  • // an array of int
  • //解决validator验证插件多个name相同只验证第一的问题
  • @property python知乎_Python3基础之:property
  • [ solr入门 ] - 利用solrJ进行检索
  • [Android]Android P(9) WIFI学习笔记 - 扫描 (1)
  • [AX]AX2012 R2 出差申请和支出报告
  • [C#]猫叫人醒老鼠跑 C#的委托及事件