How can I disable auto compaction in couchdb 3.2? I want to preserve all the history for a specific database. Or completely disable auto compaction.
note) couchdb(3.2) configuration has changed from 2.0
How can I disable auto compaction in couchdb 3.2? I want to preserve all the history for a specific database. Or completely disable auto compaction.
note) couchdb(3.2) configuration has changed from 2.0
Copyright © 2021 Jogjafile Inc.
I got an answer from github issue page.(https://github.com/apache/couchdb-documentation/issues/734) Below is the contents.
We do not advise pausing compaction to preserve the history of database. Once database revisions reach past 1000 (_revs_limit) they will start to be removed anyway. Database history should be preserved by the application. When documents are updated, can create a separate document with the old contents and link them together with an ID.
Compaction can be disabled if there is an operational issue of some sort, There is a [smoosh.ignore] $dbshard = true configuration value which can be set for individual shards. For instance:
But you'll have to list all the db shards there.
If you want to disable all dbs compaction can try: