benoitc/couchbeam — Issue #66: gen_changes continuous changes  notification errors out after second timeout
Author: aceleste
Created: 2012-01-04 11:03:14+00:00
State: open

*description of failure:* when starting a module with gen_changes behaviour with a continuous change option, the first changes request issued by gen_changes will work. Then after the default 60s timeout the connection is closed by the couchdb server. gen_changes restarts the connection, issuing a request with option `since=your_changes_last_seq`. If no more change happens on the database, a second timeout will occur, but gen_changes will then issue a request with option `since=undefined` which is malformed and thus will put the server into error and close the connection. It then loops restarting an failing forever.

*conditions for failure:* using test_gen_changes with options `[continuous, include_docs, {filter,"app/filtername}]`

*more info:* the malformed request not only contains one `since=undefined` option, but many (it may help finding out where in the code that is produced.