Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HF Servlets & JSP - POST Idempotent? Pg 114

 
Chengwei Lee
Ranch Hand
Posts: 884
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
At page 114, bottom (inverted), it was printed that POST is considered idempotent by the HTTP 1.1 spec, I suppose this is another typo?
 
Kathy Sierra
Cowgirl and Author
Rancher
Posts: 1589
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yikes! That's one bad typo! Yes, it should definitely say "POST is considered NOT idempotent..."

Which it says in a big headline on page 116.

According to the HTTP 1.1 spec, POST is not idempotent, since there is an implication that you can use POST to make changes on the server side, whereas GET is considered idemptotent.

But of course that means that YOU must be responsible for making sure that you do not use GET to do something that is inherently NOT idempotent (like using GET parameters to update something on the server). It is up to YOU (the developer) to make sure that what you do with GET requests is idempotent, but as far as the HTTP spec is concerned, GET is always considered idempotent (even if the developer creates a non-idempotent doGet() method!).

Thanks again Cheng,
Kathy
 
Chengwei Lee
Ranch Hand
Posts: 884
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No prob
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic