- Building Microservices with Go
- Nic Jackson
- 101字
- 2021-07-15 17:28:07
Controller
A controller resource is like a procedure, this is typically used when a resource cannot be mapped to standard CRUD (create, retrieve, update, and delete) functions.
The names for controllers appear as the last segment in a URI path with no child resources. If the controller requires parameters, these would typically be included in the query string:
POST /cats/1/feed -> Feed cat 1
POST /cats/1/feed?food=fish ->Feed cat 1 a fish
When defining a controller name we should always use a verb. A verb is a word that indicates an action or a state of being, such as feed or send.
推薦閱讀
- 零基礎學Visual C++第3版
- 深入淺出Spring Boot 2.x
- 從程序員到架構師:大數據量、緩存、高并發、微服務、多團隊協同等核心場景實戰
- 名師講壇:Java微服務架構實戰(SpringBoot+SpringCloud+Docker+RabbitMQ)
- Oracle Database 12c Security Cookbook
- 重學Java設計模式
- C#程序設計基礎:教程、實驗、習題
- 軟件測試技術指南
- Orchestrating Docker
- Troubleshooting Citrix XenApp?
- Learning Splunk Web Framework
- Mobile Forensics:Advanced Investigative Strategies
- 大規模語言模型開發基礎與實踐
- 安卓工程師教你玩轉Android
- Learning D3.js 5 Mapping(Second Edition)