title: Put versus Post - REST
body: <p>While looking at the code in "petclinic", part of Spring 3.0 samples I noticed the following lines  </p>
  
  <pre><code>&lt;c:choose&gt;
    &lt;c:when test="${owner.new}"&gt;&lt;c:set var="method" value="post"/&gt;&lt;/c:when&gt;
    &lt;c:otherwise&gt;&lt;c:set var="method" value="put"/&gt;&lt;/c:otherwise&gt;
  &lt;/c:choose&gt;
  </code></pre>
  
  <p>In this discussion at <a href="https://stackoverflow.com/questions/630453/put-vs-post-in-rest">SO</a> it seems that PUT should be used for "create/update" and POST for "updates".  </p>
  
  <p>Which is right?   </p>
  
  <p>What is the impact of using post for "create" and put for "update"?  </p>
  
  <p>Note : According to the HTTP/1.1 spec. quoted in the referenced SO discussion, the code given above seems to have the correct behavior.</p>