用Spring Boot编写RESTful API 学习笔记

  • REST 是 Representational State Transfer 的缩写
  • 所有的东西都是资源,所有操作都通过对资源的增删改查 (CRUD) 实现
  • 对资源的增删改查对应对 URL 的操作 (POST, DELETE, PUT, GET)
  • 无状态的

URL 中都应该是名词,不应该出现动词

关于 RESTful API 更详细可参考阮一峰老师的 RESTful API 最佳实践

RestController

Spring Boot 2.x 编写 RESTful API (一) RESTful API 介绍 & RestController

源码:spring-boot-2-restful

相关文章:

  • 2021-08-08
  • 2021-08-20
  • 2022-03-07
  • 2021-01-18
  • 2021-09-25
  • 2018-09-20
猜你喜欢
  • 2021-05-21
  • 2022-01-11
  • 2022-01-22
  • 2021-08-17
  • 2022-12-23
  • 2022-01-24
  • 2021-06-01
相关资源
相似解决方案