Why does "missing" mean when I look at the revision history of a Cloudant document

118 Views Asked by At

When I try to see the revision history of a document in Cloudant using the /<DB>/<doc_id>?revs_info=true call I get the following:

"_revs_info": [
{
"rev": "4-xxx",
"status": "available"
},
{
"rev": "3-xxx",
"status": "missing"
},
{
"rev": "2-xxx",
"status": "missing"
},
{
"rev": "1-xxx",
"status": "missing"
}

What does status:missing mean?

1

There are 1 best solutions below

0
Daniel Mermelstein On

In Cloudant, old revisions are regularly purged using a process called compaction, which is designed to manage the size of your database. Once a revision of a document is superseded, it eventually gets compacted by a background task. Once that happens, the revision's content is no longer available and you get the missing status message.

Because compaction works in the background asynchronously, you should not think of or use revisions as a way of accessing old versions of documents because it will let you down!

There is more information about revisions in this blog post