[ https://issues.apache.org/jira/browse/COUCHDB-791?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12877426#action_12877426 ]
Chris Anderson commented on COUCHDB-791: ---------------------------------------- We even have a test that the last second of updates are lost here: http://svn.apache.org/repos/asf/couchdb/trunk/share/www/script/test/delayed_commits.js I'm wary of introducing the concept of a normal shutdown. How often do you shutdown a live server? I'm guessing it's something you have never done. Servers go down because they run out of memory, or get struck by lightning. Outside of your test scenario, it is hard to see when a server under load would ever be shutdown cleanly. Which is why it doesn't make sense to have a clean shutdown mode. It is trivial to configure couchdb to force a commit for every write, and as I mentioned before, under concurrent load, it is much faster. Under single user load it is dog slow (10-ish writes per second) which is why we ship with delayed_commits on by default. I think couchdb -d is just a shell script, so if it called /_ensure_full_commit before it kills the pid, that'd be OK. But core CouchDB shouldn't have shutdown code in it. > Changes not written if server shutdown during delayed_commits period > -------------------------------------------------------------------- > > Key: COUCHDB-791 > URL: https://issues.apache.org/jira/browse/COUCHDB-791 > Project: CouchDB > Issue Type: Bug > Affects Versions: 0.11.1 > Environment: Linux (Ubuntu 10.04) > Reporter: Matt Goodall > > If the couchdb server is shutdown (couchdb -d, Ctrl+C at the console, etc) > during the delayed commits period then buffered updates are lost. > Simple script to demonstrate the problem is: > db=http://localhost:5984/scratch > curl $db -X DELETE > curl $db -X PUT > curl $db -X POST -d '{}' > /path/to/couchdb/bin/couchdb -d > When couchdb is started again the database is empty. > Affects 0.11.x and trunk branches. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.