Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-7408

Incorrect return code from deletion of a nonexistent design document

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Critical
    • 3.0
    • 2.0
    • RESTful-APIs
    • Security Level: Public
    • Untriaged

    Description

      I'm getting 200 no matter what I name I put on the design document I want to delete instead of a 404 I would expect..

      trond@ok:1363> curl -v -X GET -H 'Content-Type: application/json' 'http://192.168.0.61:8092/default/_design/bug' ~/compile/couchbase/sdk/php

      • About to connect() to 192.168.0.61 port 8092 (#0)
      • Trying 192.168.0.61...
      • connected
      • Connected to 192.168.0.61 (192.168.0.61) port 8092 (#0)
        > GET /default/_design/bug HTTP/1.1
        > User-Agent: curl/7.24.0 (x86_64-apple-darwin12.0) libcurl/7.24.0 OpenSSL/0.9.8r zlib/1.2.5
        > Host: 192.168.0.61:8092
        > Accept: /
        > Content-Type: application/json
        >
        < HTTP/1.1 404 Object Not Found
        < Server: MochiWeb/1.0 (Any of you quaids got a smint?)
        < Date: Thu, 13 Dec 2012 08:12:42 GMT
        < Content-Type: text/plain;charset=utf-8
        < Content-Length: 41
        < Cache-Control: must-revalidate
        < {"error":"not_found","reason":"missing"}
      • Connection #0 to host 192.168.0.61 left intact
      • Closing connection #0
        trond@ok:1364> curl -v -X DELETE -H 'Content-Type: application/json' 'http://192.168.0.61:8092/default/_design/bug' ~/compile/couchbase/sdk/php
      • About to connect() to 192.168.0.61 port 8092 (#0)
      • Trying 192.168.0.61...
      • connected
      • Connected to 192.168.0.61 (192.168.0.61) port 8092 (#0)
        > DELETE /default/_design/bug HTTP/1.1
        > User-Agent: curl/7.24.0 (x86_64-apple-darwin12.0) libcurl/7.24.0 OpenSSL/0.9.8r zlib/1.2.5
        > Host: 192.168.0.61:8092
        > Accept: /
        > Content-Type: application/json
        >
        < HTTP/1.1 200 OK
        < Server: MochiWeb/1.0 (Any of you quaids got a smint?)
        < Date: Thu, 13 Dec 2012 08:12:50 GMT
        < Content-Type: text/plain;charset=utf-8
        < Content-Length: 31
        < Cache-Control: must-revalidate
        < {"ok":true,"id":"_design/bug"}
      • Connection #0 to host 192.168.0.61 left intact
      • Closing connection #0

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            ketaki Ketaki Gangal (Inactive)
            trond Trond Norbye
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty