Skip to content

Garbage Collection not functioning properly during document attach process #980

@bytegallery

Description

@bytegallery

What happened:
When attaching a document, the garbageCollect() method does not function correctly in version 0.6.7. During the document attach process, garbageCollect() is called while applying the change pack, but tombstones still remain afterward. It appears that tombstones are only properly cleaned up after a subsequent push-pull operation.

What you expected to happen:
I expected that during the document attach process, all tombstones would be collected and removed immediately, leading to a clean state without any lingering tombstones.

How to reproduce it (as minimally and precisely as possible):
The issue can be reproduced using the codemirror example of yorkie-js-sdk. You can observe the presence of tombstones in the SplayTree and LLRBTree right after the attach process.

Image

Anything else we need to know?:

Environment:

  • Operating system:
  • Browser and version:
  • Yorkie version (use yorkie version):
  • Yorkie JS SDK version: v0.6.7

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug 🐞Something isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions