書名: Building Microservices with Go作者名: Nic Jackson本章字數(shù): 79字更新時間: 2021-07-15 17:28:08
CRUD function names
When designing great REST URIs we never use a CRUD function name as part of the URI, instead we use a HTTP verb. For example:
DELETE /cats/1234
We do not include the verb in the name of the method as this is specified by the HTTP verb, the following URIs would be considered an anti-pattern:
GET /deleteCat/1234
DELETE /deleteCat/1234
POST /cats/1234/delete
When we look at HTTP verbs in the next section this will make more sense.
推薦閱讀
- What's New in TensorFlow 2.0
- 零基礎玩轉區(qū)塊鏈
- Offer來了:Java面試核心知識點精講(原理篇)
- 算法大爆炸:面試通關步步為營
- Visual Basic程序設計教程
- Learn WebAssembly
- 碼上行動:用ChatGPT學會Python編程
- Domain-Driven Design in PHP
- 機器學習微積分一本通(Python版)
- 平面設計經(jīng)典案例教程:CorelDRAW X6
- Windows Phone 8 Game Development
- ABAQUS6.14中文版有限元分析與實例詳解
- 關系數(shù)據(jù)庫與SQL Server 2012(第3版)
- Python機器學習
- Serverless從入門到進階:架構、原理與實踐