Search code examples
couchbasecouchbase-sync-gateway

Couchbase sync gateway:: After make some update in document. I not get immediately update in view


If I add the new document in Couchbase Sync Gateway and try to fetch from the view, I do not get that document immediately, but after some time I get that document.

What I miss??


Solution

  • I did some testing and fined this post.

    Thanks @shirshir for suggesting that. You're right - for Couchbase Server 3.0 and higher, the indexable flag is no longer required on write for a 'read-your-own-write' scenario - you should be able to do a standard write and then a query with stale=false to see that data.

    For Couchbase Server versions 2.x I believe you'd still need to force persistence (with Indexable) on the write to ensure you're going to see the results in your stale=false query.

    I also use that flag and now it works fine.