惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园_首页
Microsoft Security Blog
Microsoft Security Blog
云风的 BLOG
云风的 BLOG
B
Blog
The Register - Security
The Register - Security
L
LangChain Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
N
Netflix TechBlog - Medium
F
Full Disclosure
The GitHub Blog
The GitHub Blog
Recorded Future
Recorded Future
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
Blog — PlanetScale
Blog — PlanetScale
Jina AI
Jina AI
美团技术团队
宝玉的分享
宝玉的分享
Hugging Face - Blog
Hugging Face - Blog
阮一峰的网络日志
阮一峰的网络日志
G
Google Developers Blog
大猫的无限游戏
大猫的无限游戏
S
SegmentFault 最新的问题
D
DataBreaches.Net
Martin Fowler
Martin Fowler
H
Hackread – Cybersecurity News, Data Breaches, AI and More
Google DeepMind News
Google DeepMind News
WordPress大学
WordPress大学
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - Franky
The Cloudflare Blog
博客园 - 【当耐特】
U
Unit 42
月光博客
月光博客
T
The Blog of Author Tim Ferriss
博客园 - 叶小钗
博客园 - 聂微东
I
InfoQ
B
Blog RSS Feed
Apple Machine Learning Research
Apple Machine Learning Research
Cyberwarzone
Cyberwarzone
V
V2EX
S
Securelist
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
S
Security @ Cisco Blogs
PCI Perspectives
PCI Perspectives
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
H
Heimdal Security Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
The Hacker News
The Hacker News
D
Darknet – Hacking Tools, Hacker News & Cyber Security
T
Tor Project blog

博客园 - MvloveYouForever

flutter重新学习 uniapp简单移动端H5电脑端适配方案 添加ssh后,ssh-rsa fatal: Could not read git合并提交 cordova打印插件备注 H5开发类似rpx实现方法 maven仓库地址 idea与其他软件激活办法 linux常用命令总结 Command line is too long mysql安装教程备份 mybatis-plus 条件参数说明 关于打包electron应用 关于spring unicloud短信不能用 关于mybatis vue2 和 vue3的区别 父子组件v-modle,vue2和vue3的区别 Vue3知识点
关于maven
MvloveYouForever · 2024-09-02 · via 博客园 - MvloveYouForever

1、依赖范围

①  complie 默认范围,编译和运行时失效,打包的时候也会打包。

②  provided 编译和测试有效、运行时无效,打包不打包。

③ runtime 编译不生效、运行生效。

④  test  编译和运行测试有效。实际运行不生效。

2、依赖冲突调解

①  第一原则:最短路径原则

②  第二原则:最先声明原则

③  排除依赖: 手动排除依赖

    锁定版本

   增加 <dependencyManagement>

 3、父子工程

1、创建一个maven工程,创建时不选择模版

父工程dom.xml

 配置tomcat插件

搭建子工程(模块)

 搭建第二个子工程,并依赖Dao

 创建controller工程,需要导入web工程模版

  注:父工程有的依赖,子工程中都删除

 运行工程,直接运行父工程

 添加运行方式maven,选择运行目录为:父工程。命令:tomcat7:run

4、maven父子工程依赖失效: 

 遇到依赖失效,直接再引一次就好。