On 22.07.2013, at 19:23, Filippo Fadda <[email protected]> wrote:
> 2) heartbeat is not expressed in milliseconds like for _changes, but you can > pass just true or false. Default is "false" or "true"? That is my, admittedly ad-hoc interpretation of the code from earlier today. I might have missed something, but it looks like when `heartbeat=true`, _db_updates will send a \n instead of timing out when the timeout limit is hit. The default is true. Best, Jan -- > > On Jul 22, 2013, at 7:12 PM, Benoit Chesneau wrote: > >> If it's the same version as in rcouch: >> >> 1. correct >> 2. uncorrect >> 3. yes, useless >> 4. yes, can't really exists >> 5. yes, can't exist we are speaking about deb events >> 6. correct, we are speaking about events >> 7) yup >> others are true >> >> >> On Mon, Jul 22, 2013 at 3:58 PM, Filippo Fadda < >> [email protected]> wrote: >> >>> HI Jan, >>> >>> so the differences with _changes are: >>> >>> 1) there is no "normal" feed, "continuous" is default; >>> 2) hearbeat is not supported for "continuous" or "longpoll" feeds; >>> 3) feed style option is not supported; >>> 4) since option is not supported; >>> 5) limit option is not supported; >>> 6) descending option is not supported; >>> 7) include_docs option is obviously not supported; >>> 8) timeout is in seconds instead of milliseconds (?); >>> 9) timeout works only for "continuous" feed; >>> 10 requires admin privileges. >>> >>> All right? >>> >>> -Filippo >>> >>> On Wed, Jul 17, 2013 at 10:00 PM, Jan Lehnardt <[email protected]> wrote: >>> >>>> Hi all, >>>> >>>> I would like to propose (lazy consensus) to port the _db_updates >>>> feature from rcouch to master before the next release. >>>> >>>> The code exists in a branch on ASF git (1684-feature-db-updates). >>>> >>>> Copying the full commit status: >>>> >>>> Import _db_updates from rcouch. >>>> >>>> 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. >>>> >>>> `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. >>>> >>>> Cheers >>>> Jan >
