So far, tried with a small tree, all seems good, but a larger tree messed the sync.
Think has to be with not preserving the "deleted" relationship. Fixing that relation an trying again. 2015-04-20 16:18 GMT-05:00 Frederic Yesid Peña Sánchez < [email protected]>: > I've reading the wiki con Sync, and came across an idea: > > If i trim the revs, parents and deleted arrays at the same time, leaving > the last 20 items, do this will trim my history tree?. > > Altough i'm asking, right now i'm doing that for research. > > You will see, we have a lot of big documents because of these arrays... > > 2015-04-20 14:28 GMT-05:00 Frederic Yesid Peña Sánchez < > [email protected]>: > > Hi again. >> >> So the thing i can see in fact is the revision tree without any revisions >> in fact. >> >> So the issue here is that the "revision" info, that "list" of revisions >> is getting too long (and not that the document itself is holding a lot of >> revisions), and that may be collapsing my DB, so i'ts safe to trim that >> revision tree?? cut from 1000 lines to 20 for example?? >> >> Thanks. >> >> El lunes, 20 de abril de 2015, 13:36:40 (UTC-5), Jens Alfke escribió: >>> >>> >>> On Apr 20, 2015, at 10:56 AM, Frederic Yesid Peña Sánchez < >>> [email protected]> wrote: >>> >>> While reading the compaction code, i notice it removes the revisions who >>> reside on separate documents. >>> How are the revisions stored in Sync/Couchbase? >>> >>> >>> The key “foo” in the bucket maps to document “foo” in the database. It >>> contains an extra internal property “_sync” that stores metadata the >>> Gateway uses. Inside that, “revisions” (sp?) stores the revision tree in a >>> weird encoding that was designed to save space. >>> >>> The revision tree only stores a revision’s body if it’s an active >>> conflict. Other revisions (ones that have been updated) have their bodies >>> moved out into separate docs in the bucket, whose keys are of the form >>> “_sync:rev:” followed by the docID and revID. These docs have an expiration >>> time of 5 minutes so Couchbase Server cleans them up automatically. >>> >>> The revision tree itself gets ‘pruned’ during every document update. >>> Nodes that are too far from any leaf are deleted. Note that active >>> conflicts are leaves, so if the doc has a lot of conflicts going back >>> through its history, they’ll effectively keep anything from getting pruned. >>> >>> —Jens >>> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "Couchbase Mobile" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/mobile-couchbase/GnT4-qYJwgA/unsubscribe >> . >> To unsubscribe from this group and all its topics, send an email to >> [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/mobile-couchbase/649d1bf2-88ca-475a-84f3-1bc1764c1ad4%40googlegroups.com >> <https://groups.google.com/d/msgid/mobile-couchbase/649d1bf2-88ca-475a-84f3-1bc1764c1ad4%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -- You received this message because you are subscribed to the Google Groups "Couchbase Mobile" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/mobile-couchbase/CAD0KcgW1JSLHK-sgQ4y6J3gt76UOo2S5vG0ORWO_m4PVDuAQrg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
