This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

a question about HTTP method

 
dx wu
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which HTTP method has the characteristic that multiple identical requests
may produce side effect beyond those of a single request?
A.PUT
B.GET
C.INFO
D.POST
E.HEAD
F.TRACE
thanks for someone help me!
 
Kejal Shah
Ranch Hand
Posts: 87
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
is the answer B?
 
Debashish Chakrabarty
Ranch Hand
Posts: 231
Firefox Browser Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
(Answers: A,C,D & F) Only GET and HEAD are considered idempotent, all others when invoked with multiple identical requests may produce side effect.
 
Kejal Shah
Ranch Hand
Posts: 87
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Debashish et al.
It was a typo from my side. I meant the ans as D. Post.

I just checked the HTTP 1.1 spec (http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html) and found the ff. quote


" Methods can also have the property of "idempotence" in that (aside from error or expiration issues) the side-effects of N > 0 identical requests is the same as for a single request. The methods GET, HEAD, PUT and DELETE share this property. Also, the methods OPTIONS and TRACE SHOULD NOT have side effects, and so are inherently idempotent."

tat leaves us with the ans of POST.
HTH
 
Debashish Chakrabarty
Ranch Hand
Posts: 231
Firefox Browser Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oh Ya TRACE should not be in the answers. Apologies!
 
Sar Lolla
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is no INFO method in HTTP.

Only PUT and POST can have side effects and nothing else.

HTTP methods
 
Kumar J
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
According to Http 1.1...PUT too is idempotent...
Refer to page 114 HFSJ...and the previous answer given by kejal...

bye

Kumar V
 
Debashish Chakrabarty
Ranch Hand
Posts: 231
Firefox Browser Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guys! Let me summarise it here for benefit of all.

The question asks about non-idempotent methods (i.e. methods that may produce side effect when invoked with multiple identical requests).

GET, HEAD, PUT and TRACE are considered idempotent. The name INFO has been given just to confuse I suppose :roll: , there is not such method.

Which leaves us with answer for the question: D. POST. POST is not idempotent.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic