We might argue that conceptually there's both a case for a 200 OK and a 204 NoContent.<div>This request is a PUT, and I agree that it should return the same thing that every PUT returns.</div><div>Also, I won't risk backward compatibility for something like this.</div>
<div><br></div><div>Nevertheless, the 'null' string in the response body looks like a bug to me.</div><div>Nachi, can you confirm what Dolph saw?</div><div><br></div><div>Salvatore<div><br><div class="gmail_quote">
On 25 October 2012 21:52, Dolph Mathews <span dir="ltr"><<a href="mailto:dolph.mathews@gmail.com" target="_blank">dolph.mathews@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
If the actual response body is the string "null" (which it looks to be, based on the bug report), then 200 OK is correct. If the response body is actually empty, then I believe 204 No Content would be more appropriate.<br clear="all">
<div><br></div><div>However, I'm guessing it's a bug that a response body is returned at all?</div><span class="HOEnZb"><font color="#888888"><div><br></div>-Dolph</font></span><div class="HOEnZb"><div class="h5">
<br>
<br><br><div class="gmail_quote">On Thu, Oct 25, 2012 at 3:07 PM, Nachi Ueno <span dir="ltr"><<a href="mailto:nachi@nttmcl.com" target="_blank">nachi@nttmcl.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi Salvatore<br>
<br>
I have question about the consistency of return code of the remove action.<br>
So currently remove_router_interface returns 200.<br>
It looks deletion of the interface , so it should be 204.<br>
<br>
remove_router_interface returns string "null"<br>
<a href="https://bugs.launchpad.net/quantum/+bug/1064727" target="_blank">https://bugs.launchpad.net/quantum/+bug/1064727</a><br>
<br>
I discussed with Dan about this.<br>
His opinion is PUT always should return 200. ( One another reason is<br>
backward compatibility with Folsom version )<br>
This is also make sense for me if all PUT method returns 200 if success.<br>
<br>
How do you think about this spec?<br>
<br>
Thanks<br>
Nachi<br>
<br>
_______________________________________________<br>
OpenStack-dev mailing list<br>
<a href="mailto:OpenStack-dev@lists.openstack.org" target="_blank">OpenStack-dev@lists.openstack.org</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
</blockquote></div><br>
</div></div><br>_______________________________________________<br>
OpenStack-dev mailing list<br>
<a href="mailto:OpenStack-dev@lists.openstack.org">OpenStack-dev@lists.openstack.org</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
<br></blockquote></div><br></div></div>