Uploaded image for project: 'Couchbase Lite'
  1. Couchbase Lite
  2. CBL-3831

Prevent unnecessary growth of RevTree's _insertedData

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 3.0.6
    • 3.0.2
    • LiteCore
    • Security Level: Public
    • None
    • 1

    Description

      Original issue and PR

      https://github.com/couchbase/couchbase-lite-core/pull/1572

      Copied from the PR

      Currently, RevTree._insertedData is copied as is when copying a RevTree.

      Why is this a problem?

      When a document is repeatedly updated, Revs start to be purged eventually. Also, Rev bodies that aren't needed anymore are removed.
      RevTree._insertedData is only ever added to and copied, keeping more and more data unnecessarily alive with each update. This data occupies memory, and the work required to copy RevTree._insertedData starts to dominate save operations.

      Task

      Port the fix from master branch to lithium branch

      https://github.com/couchbase/couchbase-lite-core/commit/7b47459416ae572fa5b884bd8c690195acd82986

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            The Lite The Lite
            pasin Pasin Suriyentrakorn
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty