You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Matt Goodall (JIRA)" <ji...@apache.org> on 2010/02/26 18:23:27 UTC

[jira] Created: (COUCHDB-675) Using _bulk_docs to delete a missing document gives success response

Using _bulk_docs to delete a missing document gives success response
--------------------------------------------------------------------

                 Key: COUCHDB-675
                 URL: https://issues.apache.org/jira/browse/COUCHDB-675
             Project: CouchDB
          Issue Type: Bug
          Components: Database Core
            Reporter: Matt Goodall


Deleting a non-existant document using _bulk_docs should return not_found but instead appears to work, returning a "1-xxx" deletion rev. The deletion even appears in the changes.

$ curl http://localhost:5984/scratch -X PUT
{"ok":true}
$ curl http://localhost:5984/scratch/_bulk_docs -X POST -d '{"docs": [{"_id": "foo", "_deleted": true}]}'
[{"id":"foo","rev":"1-de715bf126efc93d225d9e3f8e8eb81a"}]
$ curl http://localhost:5984/scratch/_changes
{"results":[
{"seq":1,"id":"foo","changes":[{"rev":"1-de715bf126efc93d225d9e3f8e8eb81a"}],"deleted":true}
],
"last_seq":1}


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-675) Using _bulk_docs to delete a missing document gives success response

Posted by "Paul Joseph Davis (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-675?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Joseph Davis updated COUCHDB-675:
--------------------------------------

    Skill Level: Regular Contributors Level (Easy to Medium)

> Using _bulk_docs to delete a missing document gives success response
> --------------------------------------------------------------------
>
>                 Key: COUCHDB-675
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-675
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Database Core
>            Reporter: Matt Goodall
>
> Deleting a non-existant document using _bulk_docs should return not_found but instead appears to work, returning a "1-xxx" deletion rev. The deletion even appears in the changes.
> $ curl http://localhost:5984/scratch -X PUT
> {"ok":true}
> $ curl http://localhost:5984/scratch/_bulk_docs -X POST -d '{"docs": [{"_id": "foo", "_deleted": true}]}'
> [{"id":"foo","rev":"1-de715bf126efc93d225d9e3f8e8eb81a"}]
> $ curl http://localhost:5984/scratch/_changes
> {"results":[
> {"seq":1,"id":"foo","changes":[{"rev":"1-de715bf126efc93d225d9e3f8e8eb81a"}],"deleted":true}
> ],
> "last_seq":1}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.