Is REST only for Web APIs? If not, then what other systems can obey REST apart from Web APIs?

蹲街弑〆低调 提交于 2020-07-15 15:14:04

问题


I hear people say as per Roy Feilding that REST is not just for web services. If so, what other systems/mechanisms/anything can use it?


回答1:


The REST interface is designed to be efficient for large-grain hypermedia data transfer -- Fielding, 2000.

REST is intended for long-lived network-based applications that span multiple organizations -- Fielding, 2008

The problem, of course, is that if that's what you need -- the web is sitting right there, so in most cases it's going to be more practical to adapt to the web as is, and perhaps extend it a little bit in a useful direction.

The alternative requires not only re-inventing the wheel, but also persuading the world to adopt the new standard and use it.




回答2:


Any system that has some type of access to the server, can even be an onboard system that has access to the API network




回答3:


Any system that uses URIs to communicate information would be able to use REST.

Example: a theoretical database that fully follows REST rules.

Example resource "serverhost/database/table/1"



来源:https://stackoverflow.com/questions/62730975/is-rest-only-for-web-apis-if-not-then-what-other-systems-can-obey-rest-apart-f

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!