Hypertext Transfer Protocol (HTTP) Question:
Download Job Interview Questions and Answers PDF
What is Idempotent methods in HTTP?
Answer:
These methods achieve the same result, no matter how many times the request is repeated: they are GET, PUT, and DELETE. The only non idempotent method is POST. PUT and DELETE being considered idempotent might be surprising, though, it, in fact, is quite easy to explain: repeating a PUT method with exactly the same body should modify a resource in a way that it remains identical to the one described in the previous PUT request: nothing will change! Similarly, it makes no sense to delete a resource twice. It follows that no matter how many times a PUT or DELETE request is repeated, the result should be the same as if it had been done only once.
Download HTTP Interview Questions And Answers
PDF
Previous Question | Next Question |
What are the safe and unsafe methods of HTTP? | What is Representations in HTTP? |