3 ms·
> If it's your own server you can do whatever you want. This is not at all true. For example, say I'm a user in a dorm that uses a proxy that I have no contro
by jedberg 7y ago
> If it's your own server you can do whatever you want.
This is not at all true. For example, say I'm a user in a dorm that uses a proxy that I have no control over. If you make your GET request modify things, that proxy may cache the request, or worse, may repeat the request later to maintain its cache.
My point is, you don't know what is between your server and their client, and even well behaved infrastructure will sometimes make or modify GET requests on your behalf, but won't do that with POSTs.
- jonny_eh 7y agoIt's also an issue when you don't even fully control the client, which in this case is the web browser. A game at least behaves exactly as you program it. Browsers are not necessarily consistent, especially when you throw in extensions.
- jedberg 7y agoYes excellent point. Some browsers/plugins will prefetch every GET on the page to speed up browsing.
- Rebelgecko 7y agoSome browsers also show a "here's your top 10 most visited webpages" shortcut when you make a new tab, which does a GET. I ran into that one when I was being lazy about building/testing an API.
- justinhj 7y agoIn the Hacker News case there isn't a GET request on the page, it's triggered by the javascript so this would not happen
- justinhj 7y agoThere are ways to make sure that your GET requests are not cached. For example in the case we're talking about here the server sets that URI to have "Cache-Control: private; max-age=0". Now sure, a proxy could simply ignore HTTP protocol and cache it anyway, but that would break a lot of things and AFAIK is not seen often in the wild. Certainly in the case of the applications I worked on we did not have customers that reported connection difficulties over HTTP.