for-GET / http-decision-diagram

An activity diagram to describe the resolution of HTTP response status codes, given various headers.
https://github.com/for-GET/http-decision-diagram/blob/master/doc/2013-06-10-http-hell-no.md
Apache License 2.0
3.6k stars 196 forks source link

why i7 moved? #53

Open declaresub opened 6 years ago

declaresub commented 6 years ago

What is the idea behind the decision branch i7 moved? As best as I can tell, it serves only as a possible short-circuit for skipping the next decisions moved_permanently, moved_temporarily, gone_permanently.

andreineculau commented 6 years ago

Once again, sorry for the late reply.

You are right that it's a shortcircuit, as it is also seen from the diagram. So if you have the means to confirm that the resource has moved e.g. /profile/1234567890 has moved to /user/andrei.neculau, then this hook should return true, allowing for the other moved_* hooks to decide which type of resource-move was performed.

In retrospect, I agree with what you're implying i.e. why have it at all? I'll leave this open, and mark it as enhancement (simplification).