You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Alexander Shorin (JIRA)" <ji...@apache.org> on 2015/04/19 12:22:59 UTC

[jira] [Closed] (COUCHDB-2668) Regression: attachment Etag references to document revision, not to digest

     [ https://issues.apache.org/jira/browse/COUCHDB-2668?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexander Shorin closed COUCHDB-2668.
-------------------------------------
    Assignee: Robert Newson

> Regression: attachment Etag references to document revision, not to digest
> --------------------------------------------------------------------------
>
>                 Key: COUCHDB-2668
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-2668
>             Project: CouchDB
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Database Core, HTTP Interface
>            Reporter: Alexander Shorin
>            Assignee: Robert Newson
>            Priority: Blocker
>             Fix For: 2.0.0
>
>
> In CouchDB 1.6.1:
> {code}
> $ curl -XPUT http://localhost:5984/db/doc/att -d 'Hello, CouchDB!' -H "Content-Type: text/plain"
> {"ok":true,"id":"doc","rev":"1-3ead39fb9d2538602f817e0bdc00fe26"}
> $ curl -XGET -v http://localhost:5984/db/doc/att
> * Hostname was NOT found in DNS cache
> *   Trying 127.0.0.1...
> * Connected to localhost (127.0.0.1) port 5984 (#0)
> > GET /db/doc/att HTTP/1.1
> > User-Agent: curl/7.39.0
> > Host: localhost:5984
> > Accept: */*
> > 
> < HTTP/1.1 200 OK
> < Server: CouchDB/1.7.0 (Erlang OTP/17)
> < ETag: "+4vGmBKGmQoMe7ojcTyiSA=="
> < Date: Sun, 19 Apr 2015 01:17:41 GMT
> < Content-Type: text/plain
> < Content-Length: 15
> < Cache-Control: must-revalidate
> < Accept-Ranges: none
> < 
> * Connection #0 to host localhost left intact
> Hello, CouchDB!%   
> {code}
> In CouchDB 2.0:
> {code}
> $ curl -XPUT http://localhost:15984/db/doc/att -d 'Hello, CouchDB!' -H "Content-Type: text/plain"
> {"ok":true,"id":"doc","rev":"1-3ead39fb9d2538602f817e0bdc00fe26"}
> $ curl -XGET -v http://localhost:15984/db/doc/att
> * Hostname was NOT found in DNS cache
> *   Trying 127.0.0.1...
> * Connected to localhost (127.0.0.1) port 15984 (#0)
> > GET /db/doc/att HTTP/1.1
> > User-Agent: curl/7.39.0
> > Host: localhost:15984
> > Accept: */*
> > 
> < HTTP/1.1 200 OK
> < Server: CouchDB/42c9047 (Erlang OTP/17)
> < ETag: "1-3ead39fb9d2538602f817e0bdc00fe26"
> < Date: Sun, 19 Apr 2015 01:14:11 GMT
> < Content-Type: text/plain
> < Content-Length: 15
> < Cache-Control: must-revalidate
> < Accept-Ranges: none
> < 
> * Connection #0 to host localhost left intact
> Hello, CouchDB!%
> {code}
> If document becomes updated, but attachment does not, their Etag changes as well:
> {code}
> $ curl -XGET -v http://localhost:15984/db/doc/att
> * Hostname was NOT found in DNS cache
> *   Trying 127.0.0.1...
> * Connected to localhost (127.0.0.1) port 15984 (#0)
> > GET /db/doc/att HTTP/1.1
> > User-Agent: curl/7.39.0
> > Host: localhost:15984
> > Accept: */*
> > 
> < HTTP/1.1 200 OK
> < Server: CouchDB/42c9047 (Erlang OTP/17)
> < ETag: "3-90c8a1947115ffb2032a217ed3d3c624"
> < Date: Sun, 19 Apr 2015 01:15:55 GMT
> < Content-Type: text/plain
> < Content-Length: 15
> < Cache-Control: must-revalidate
> < Accept-Ranges: none
> < 
> * Connection #0 to host localhost left intact
> Hello, CouchDB!%
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)