3 ms·
Here is an example: https://developers.google.com/fit/rest/v1/datasets#get_a_dataset https://developers.google.com/fit/rest/v1/datasets#get_a_dat... It says:
by theamk 4y ago
Here is an example:
https://developers.google.com/fit/rest/v1/datasets#get_a_dataset https://developers.google.com/fit/rest/v1/datasets#get_a_dat...
It says: "To get a dataset, do HTTP GET to this URL. The result is a JSON document". Notably, this does not _look_ like RPC call -- there is no "getData" anywhere, no {"status": "ok"} field. Instead, this is pretty identical to how you would access a static directory with weirdly-named files.
(If you never worked with "static directory with weirly-named files" API, here is an example: ftp://ftp.swpc.noaa.gov/pub/forecasts/45DF/ . To fetch data, you access file named "{MM}{DD}45DF.txt" (via FTP, no less!), get the document and parse. The REST is a modern equivalent of this.)
NotablyThis does not sound like a "getData()" function
- LudwigNagasena 4y agoEven disregarding the argument that those differences wouldn't warrant the asserted distinction, > there is no "getData" anywhere Here it is: HTTP method GET > no {"status": "ok"} field And here it is: "The response is a 200 OK status code."
- theamk 4y agoUnder the same logic, would you call fetching static file "RPC call"? What about fetching a static file via FTP (per my other example) or Gopher -- is this RPC as well? In general, do you think it is possible at all to have a request/response protocol which is _not_ RPC?
- LudwigNagasena 4y ago> Under the same logic, would you call fetching static file "RPC call"? What about fetching a static file via FTP (per my other example) or Gopher -- is this RPC as well? Fetching stuff over FTP, Gopher or HTTP is not RPC per se. Just as merely using classes, or not using classes, doesn't mean that you do or don't adhere to OOP. > In general, do you think it is possible at all to have a request/response protocol which is _not_ RPC? RPC means that you call functions that require remote execution similarly to the way you call local functions. If what you are doing doesn't fit that paradigm semantically, it isn't RPC.