Hi Clay,

Thanks for your information. I am sorry that I made a mistake. You're right that
HEAD object returns 200 not 204, that's perfectly ok.

Meanwhile, HEAD account / container return 204 with Content-Length: 0. This is 
against
RFC7230, but from the discussion on the Change-Id: 
I5ab1eb85e777f259f4bd73a3a4a1802901925ed7
I understand that it can't be fixed in an easy way, and may not be worth the 
effort anyway.

Atsuo
--
                                       Ouchi Atsuo / ouchi.at...@jp.fujitsu.com
                                                                Fujitsu Limited


-----Original Message-----
From: Clay Gerrard [mailto:clay.gerr...@gmail.com] 
Sent: Thursday, May 07, 2015 1:54 PM
To: OpenStack Development Mailing List (not for usage questions)
Subject: Re: [openstack-dev] [Swift] HEAD Object API status code

Can you give an example of an Object HEAD request returning 204?  I tried a 
HEAD of an object with a body and also a HEAD of an object of length 0 and I 
seem to get 200's...

Container's and accounts are a little more interesting story... [2]

-Clay

2. https://review.openstack.org/#/c/32647/

On Wed, May 6, 2015 at 5:40 PM, Ouchi, Atsuo <ouchi.at...@jp.fujitsu.com> wrote:


        Hello Swift developers,
        
        I would like to ask you on a Swift API specification.
        
        Swift returns 204 status code to a valid HEAD Object request with a 
Content-Length header,
        whereas the latest HTTP/1.1 specification (RFC7230) states that you 
must not send
        the header with a 204 status code.
        
        > 3.3.2.  Content-Length
        (snip)
        >    A server MUST NOT send a Content-Length header field in any 
response
        >    with a status code of 1xx (Informational) or 204 (No Content).  A
        >    server MUST NOT send a Content-Length header field in any 2xx
        >    (Successful) response to a CONNECT request (Section 4.3.6 of
        >    [RFC7231]).
        
        What I would like to know is, when you designed Swift APIs what was the 
reasoning
        behind choosing 204 status code to HEAD Object, over other status codes 
such as 200?
        
        Thanks,
        Atsuo
        --
                                               Ouchi Atsuo / 
ouchi.at...@jp.fujitsu.com
                                                   tel. 03-6424-6612 / ext. 
72-60728968
                            Service Development Department, Foundation Service 
Division
                                                                        Fujitsu 
Limited
        
        
        
__________________________________________________________________________
        OpenStack Development Mailing List (not for usage questions)
        Unsubscribe: 
openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
        http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
        


__________________________________________________________________________
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

Reply via email to