Uploaded image for project: 'CouchDB'
  1. CouchDB
  2. COUCHDB-735

Support HTTP POST for the change notification filter API

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.11
    • None
    • HTTP Interface
    • None
    • Regular Contributors Level (Easy to Medium)

    Description

      Currently the change notification filters only support HTTP GET. This limits their usefulness for cases where the filter criteria passed in exceed URL query length limitations. If the API supports HTTP POST, the filter function can then inspect the BODY of the request for filtering criteria.

      I started a discussion on the mailing list here: http://mail-archives.apache.org/mod_mbox/couchdb-user/201004.mbox/browser. Chris suggested that I modify the change API to support POST (in the Erlang code) myself as an experiment. I was able to verify that the filter function was able to see the BODY of the request. However, the changes feed (with the filtering function) hangs whenever there is a BODY in the request (for both GET and POST verbs).

      I'm attaching a patch that contains the change Chris proposed as well as the updated Futon JavaScript test file for the changes API. The test currently times out (and fails). It should work once the feature is implemented.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ningtan Ning Tan
              Votes:
              5 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: