[MB-4814] Checkpoint only needs to maintain keys and subset of meta data fields. ( memory optimization) Created: 16/Feb/12  Updated: 31/Jan/14  Resolved: 16/Feb/12

Status: Resolved
Project: Couchbase Server
Component/s: couchbase-bucket
Affects Version/s: 1.8.0
Fix Version/s: 2.0-beta
Security Level: Public

Type: Improvement Priority: Major
Reporter: Chiyoung Seo Assignee: Chiyoung Seo
Resolution: Fixed Votes: 0
Labels: 1.8.1-release-notes
Remaining Estimate: 8h
Time Spent: Not Specified
Original Estimate: 8h


 Description   
The previous checkpoint implementation requires each checkpoint to maintain the list of keys, their values, and all of their meta data fields, which can cause very high memory overhead in case disk write throughput or replication is very slow.

Based on various use cases for checkpoint, it turns out that it is not necessary to maintain the strong consistency across checkpoints. This can simplify a checkpoint's item structure, which allows us to have keys and subset of their meta data fields only. Basically, a checkpoint only contains the information about which keys have been mutated and their operation types.

With this simplication, the memory overhead of a single checkpoint item (i.e., QueuedItem instance) is reduced from 88 bytes to 40 bytes. In addition, the closed checkpoint won't point to stale Blob value instances anymore.

 Comments   
Comment by Chiyoung Seo [ 16/Feb/12 ]
http://review.couchbase.org/#change,13286
Generated at Fri Apr 18 21:58:47 CDT 2014 using JIRA 5.2.4#845-sha1:c9f4cc41abe72fb236945343a1f485c2c844dac9.