This creates a new top level API endpoint: `/_db_updates` that returns a line of JSON for each database event along with the database name. A database event is one of `created`, `updated`, `deleted`. The API endpoint supports a `?feed=` parameter with the options: `longpoll`, `continuous` and `eventsource`. A second parameter `timeout=` specifies when the server should close the connection. `longpoll` closes the connection after a single notification. It is the default option. `continuous` keeps a socket open until the specified `timeout` or 60 seconds by default. `heartbeat` decides whether to send a newline character on `timeout` to avoid clients closing the connection prematurely. `eventsource` works like continuous, but sends the data in EventSource format. See http://dev.w3.org/html5/eventsource/ The parameters are modelled after the existing `/_changes` API endpoint. Note that `/_db_updates` does not support resuming of notifications via a sequence ID. This is a port of the existing DbUpdateNotification interface to the HTTP API. Functional changes compared to rcouch: - make _db_updates an admin-only resource Docs: - updated api/misc to include basic info on `/_db_updates` License: Apache 2 license, updated LICENSE. Notice: (c) 2012 Benoit Chesneau, updated NOTICE. Tests: - only manual testing of the various API differences due to complications with asynchronous HTTP requests in the JS test suite and total annoyance of overly complicated ibrowse/httpc modules for writing etap tests. Recommendation to ship this as EXPERIMENTAL until we have tests.
…rver. This allows you to write all query server functions in CoffeeScript. The implementation re-uses the JS query server and adds an additional, optional compilation step. To make the implementation easier for now, a new main-coffee.js file is generated that includes the CoffeeScript compiler, but I think we can do away with that in a future optimisation and just use a single main.js that can handle both. The patch includes basic tests for the JS test suite that I tested in Firefox and Chrome. I'm no expert in CoffeeScript, so I don't know if more complex script will break the implementation. `make distcheck` passes. Futon picks up the "coffeescript" design document lanugage as expected and view definition interaction works as usual. List functions don't deal well with the implicit return generated by CoffeeScript, but J Chris says, this will be easy to fix. The patch adds CoffeeScript 1.1.1 which is MIT licensed and updates the NOTICE, LICENSE, license.skip and .gitignore files as well as the build system accordingly. git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@1129600 13f79535-47bb-0310-9956-ffa450edef68
…es, closes COUCHDB-459 git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@802763 13f79535-47bb-0310-9956-ffa450edef68