3 ms·
Isn't it more "cache friendly" to use urls that address objects by path, instead of addressing them by query parameters? Like http://foo.com/rest/suite/foo/bar
by SimHacker 15y ago
Isn't it more "cache friendly" to use urls that address objects by path, instead of addressing them by query parameters? Like http://foo.com/rest/suite/foo/bar http://foo.com/rest/suite/foo/bar is more likely to be cached than http://foo.com/rest/suite?dir=foo&file=bar http://foo.com/rest/suite?dir=foo&file=bar or http://foo.com/rest/suite?file=bar&dir=foo http://foo.com/rest/suite?file=bar&dir=foo
- masklinn 15y agoThat is possible (for stupid caches anyway, on purely technical grounds there should be no difference), it also looks much better to developers/users and is much, much easier to map/dispatch in most frameworks. I was just talking about the restful part of the thing, your urls can look like this: http://example.org/?wubwub=9cec6c6faef8f7ccefe1bbf409368f1e3d0fa626 and still be part of a completely and perfectly restful service.