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

Collection manager API: consider allowing user to pass `history=false` for any bucket type

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Major
    • None
    • None
    • None
    • None
    • 0

    Description

      When creating or updating a collection, and passing `history=false`, the server returns HTTP status code 400 and this error message:

      {"errors":{"history":"Bucket must have storage_mode=magma, not couchstore"}} 

      This is a problem because in the collections manifest returned by the server for a non-magma bucket, every collection has a `history` field with value `false`. This makes round-tripping difficult, since propagating that "history=false" back into a create/update request triggers the 400 result.

      Proposal: relax the argument validation so the user can always pass "history=false". Return the 400 code only if the user passed `history=true` and the storage engine is not magma.

      Alternate proposal: In the collections manifest, only include the "history" field if the bucket uses magma.

      Attachments

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

        Activity

          People

            Unassigned Unassigned
            david.nault David Nault
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty