2.0.0(snapshot) 按照老师写的 使用GET请求会报 405 错误,必须用POST
或者把controller中的 POSTMapping 变成 RequestMapping
或者把controller中的 POSTMapping 变成 RequestMapping
2018-02-23
<repository>
<id>spring-milestones</id>
<name>Spring Milestones</name>
<url>https://repo.spring.io/libs-milestone</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<id>spring-milestones</id>
<name>Spring Milestones</name>
<url>https://repo.spring.io/libs-milestone</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
2018-02-08
<repository>
<id>spring-snapshots</id>
<name>Spring Snapshots</name>
<url>https://repo.spring.io/snapshot</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
<repository>
<id>spring-snapshots</id>
<name>Spring Snapshots</name>
<url>https://repo.spring.io/snapshot</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
<repository>
2018-02-08
使用2.0.0.RC1没问题,下载不到依赖是仓库问题,spring没有添加到中央仓库,所以需要自定义仓库,我用gradle的。spring.io自动添加了它的maven仓库。
repositories {
mavenCentral()
maven { url "https://repo.spring.io/snapshot" }
maven { url "https://repo.spring.io/milestone" }
}
repositories {
mavenCentral()
maven { url "https://repo.spring.io/snapshot" }
maven { url "https://repo.spring.io/milestone" }
}
2018-02-08