32 ms·
That's a pretty broad statement to make... You are assuming that out there only "your app" exists. Actually, many times "your app" is somebody else's app that
by CrLf 14y ago
That's a pretty broad statement to make... You are assuming that out there only "your app" exists.
Actually, many times "your app" is somebody else's app that you bought or an app that somebody else develops and you don't have any control over it. Sometimes those apps are just bad (well, most enterprise apps are) and your only hope is that the infrastructure that you do happen to control doesn't make it worse.
I've never used nginx, so I don't know if the parent has a point or not. However, having a reverse proxy retrying _any_ requests to backends by default seems very bad form to me. Do you want your routers resending packets? It's the same thing.
- scott_w 14y agoIf you have an app that completely ignores the HTTP specification like that then you could well have bigger problems. I recall reading about a very popular image website doing exactly that and, when Google attempted to index it, some strange things happened to the images as the web crawler chased down all those "safe" links.
- unclebucknasty 14y agoI agree with that. Automatically resenting requests is not good. Better to simply timeout. And if there are enough timeouts that it's causing a problem, the functionality should be restructured.
- derefr 14y ago> However, having a reverse proxy retrying _any_ requests to backends by default seems very bad form to me. Do you want your routers resending packets? It's the same thing. No: HTTP GET is explicitly idempotent and cachable. As an HTTP client, you are supposed to be able to send the same GET all day, and it's up to the server to not screw that up.
- CrLf 14y agoI'm not saying that it's a standards violation or anything like that. I'm not even arguing against GET retries, but only against them being default. Bad behavior from apps you don't control is a fact of life. Ignoring it doesn't make it go away, and behaving like it doesn't exist can make it worse.
- derefr 14y agoI would argue that relying on the behavior allowed by a standard is the only way to make it actually be allowed. Otherwise, people code to your unwritten, stricter standard, relying on nobody else ever sending them something that is allowed. Then, when something allowed by the standard does happen, they blow up. But once you introduce other software in the ecosystem that is guaranteed to send you these sorts of things, you'll damn well better release a new version of your package that works with them.