mysql pom.xml版本号_maven的pom.xml的依赖,什么情况下可以不写版本号?

maven的pom.xml的依赖,什么情况下可以不写版本号?

 0

 1640

b91d06217ab608a6cdd97a171ec79b2b.png

风云剑客

9cbed7d4430979d0a8c2605d45ed3dc8.gif

2019/4/23 13:57:36

江苏 苏州

以前见过的pom.xml文件,依赖中都是必须有版本号的。但今天看到别人写的一个关于SpringBoot的demo,依赖中没有版本号,也没有任何问题,项目能正常跑起来。pom.xml:

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/xsd/maven-4.0.0.xsd">

4.0.0

netgloo

spring-boot-mysql-hibernate

0.0.1-SNAPSHOT

spring-boot-mysql-hibernate

Use MySQL in Spring Boot web application with Hibernate

org.springframework.boot

spring-boot-starter-parent

1.2.3.RELEASE

org.springframework.boot

spring-boot-starter-web

org.springframework.boot

spring-boot-starter-data-jpa

mysql

mysql-connector-java

UTF-8

netgloo.Application

1.7

org.springframework.boot

spring-boot-maven-plugin

我猜原因在这段代码里:

org.springframework.boot

spring-boot-starter-parent

1.2.3.RELEASE

但还是没想明白,为什么一些依赖如mysql连接可以忽略版本号?

有大触可以解释下吗?

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值