These commits are when the Protocol Buffers files have changed: (only the last 100 relevant commits are shown)
| Commit: | 53f467f | |
|---|---|---|
| Author: | jinho.park.s3 | |
Bound ghost GC and count ZeroTree sizes Ghost purge kept every purged node, counted it in neither live nor gc, and handed it back to GC on every snapshot load. Also, a style write changed no size at all. - A ghost is marked (`ZeroTokens.ghost`, written only for a ghost with no ghost character) and left out of the GC pairs, so a reload does not collect it again. - A purge reports what stays (`PurgeResult`), and the root moves it to live; the tree's size counts ghosts, so a reload gives the same sizes. - A ghost next to a ghost of the same insertion, each removed by one deletion of the same actor with no cancel, joins it: Backspace over pasted text leaves one ghost. - Compaction is the bound: it rebuilds from YSON and drops every ghost. - Marker changes in place (style writes, range writes spreading, cancels re-picking, GC dropping a range register) are booked in live or gc as the node is. - A style cancel that replaces an older state takes the older state out of the GC pairs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | 81c46c1 | |
|---|---|---|
| Author: | jinho.park.s3 | |
Merge main into feat/zero-tree and port ZeroTree to the new removal ledger The removal ledger this branch was stacked on landed in main in a reworked form (yorkie-js-sdk#1514 / yorkie#2310). Take main's Text and RGATreeSplit code as is and move ZeroTree onto the same rules: - Undo cancels the executing actor's own removal; restore spans no longer carry removed_by and there is no restore-removed-by capability. - The reverse of a retombstone names only the pieces the removal was recorded on. - ZeroTree nodes persist the ledger as removal_events, like TextNode. A ghost purge keeps the node and its ledger, so the purged-ledger message is gone. - ZeroTree registers itself as a ledger holder so cancelled removals are pruned with the version vector. - The unreleased ZeroTree proto messages are renumbered. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | 84068f7 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Keep Text undo converging through GC with a smaller ledger protocol (#1514) Port the Text undo removal ledger of yorkie-team/yorkie#2310, so the JS SDK runs the same rules as the Go server and writes the same snapshots. An undo no longer revives text a concurrent deletion removed, and a deletion no longer removes text a concurrent undo revived (yorkie-team/yorkie#2237). Each Text piece keeps the deletions that removed it and the undos that cancelled some of them. An undo cancels only its own actor's removal, and a deletion or redo removes only what its author saw live. GC holds a tombstone until its ledger is stable and a single deletion holds it, and prunes pairs every replica knows; a tombstone held by two deletions nobody undoes is never collected, as in Go. A piece recreated after GC is anchored before the nearest following piece of its insertion, and an empty undo edit runs as a no-op at the head of the text. Operations do not change on the wire. Snapshots gain one field, TextNode.removal_events, identical to Go; a malformed ledger is dropped with a warning. The server must run these rules first, and must not be rolled back once clients write ledgers. This takes over #1494 and keeps its two commits. Co-authored-by: jinho.park.s3 <jinho.park.s3@navercorp.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The documentation is generated from this commit.
| Commit: | 9934620 | |
|---|---|---|
| Author: | hackerwins | |
Cancel only the undoing actor's own Text removal yorkie#2310 settled the Text removal ledger on rules that need no field on the wire, and the JS SDK has to run the same ones to converge with Go and with the server's snapshots. - A restore cancels the one uncancelled removal by the actor running the undo. An actor removes a piece only while it is live in its view, so it holds at most one such removal, and RestoreSpan.removedBy, the restore-removed-by capability and dropRemovedBy go away. - recordRemoval refuses a second uncancelled removal by the same actor, which only a dishonest vector can send and which would break the pairing the snapshot encoding relies on. - A redo returns a reverse naming only the pieces it recorded a removal on, so the next undo never reaches a piece without one. - A restore that finds a piece purged recreates it with a stand-in removal by the undoing actor at lamport 0 and its cancel, as Go does. The purged-ledger side table goes; GC holds the tombstone instead. - Snapshots carry the ledger in TextNode.removal_events (field 6, as in Go's resources.proto): every removal and cancel ticket but removed_at, told apart per actor by place. A node whose removed_at says it all writes nothing, and a reader refuses events that break the rules. has_ledger, removals, removal_cancels, purged_removals and RestoreSpan.removed_by leave the proto. - Ledger walks index cancels by deletion, so reading one is linear. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The documentation is generated from this commit.
| Commit: | bdb80c7 | |
|---|---|---|
| Author: | jinho.park.s3 | |
| Committer: | hackerwins | |
Keep a Text removal the undo never saw An identity-preserving undo of a Text deletion cleared the tombstone outright, so it also revived text that a concurrent deletion it never saw had removed: from abcdefgh, B deletes d and undoes it while A deletes defgh, and A ends with abcd and B with abc depending on delivery order. The reverse case is yorkie#2237: a remote deletion removed every node whose creation it knew, including one the deleter saw removed and an undo revived here, so d1 kept efh while d2 lost f again. Each RGATreeSplitNode now keeps a removal ledger: the deletions that removed it while it was live in the deleter's view, and the undos that cancelled some of them. removedAt stays the latest uncancelled deletion, so a node no undo touched looks exactly as before. - A restore span carries removedBy, the deletion it undoes, and the restore cancels only that one. A redo records a new deletion, and the next undo names the redo. - A remote deletion removes only nodes live in the deleter's view. A node it saw live but someone else removed records the deletion anyway, so a later undo of the other deletion keeps it removed in every order. - GC keeps what a purged piece's ledger still said. A restore that finds the piece gone recreates only what no other deletion holds, piece by piece, as an unpurged replica would. - Ledgers and purged ledgers travel in snapshots, and removed_by on the wire. A server re-encodes the pack and drops fields it does not know, so removedBy is sent only while the server advertises the new restore-removed-by capability. Without it an undo drops removedBy and revives the span as every replica did before. Part of yorkie-team/yorkie#2237 (the Text half; Tree has its own path). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 0e3bb51889936b47b5d3d04c8c856255136148a6)
| Commit: | 1e58214 | |
|---|---|---|
| Author: | jinho.park.s3 | |
| Committer: | jinho.park.s3 | |
Read an atom with no data as {} when its data is an object An atom whose data is an empty object, such as Zero's soft break (empty-data), wrote no key, so it read back with no data and Zero rejected the node: a document with soft breaks did not converge in the Zero editor. ZeroSchema.objectData (proto field 10) lists the atomic types whose data is an object. Such a node with no data reads as {}. Nothing is written per node, and atoms not listed (a ProseMirror hard_break) stay without data. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | a2f9284 | |
|---|---|---|
| Author: | jinho.park.s3 | |
Fold same-place ZeroTree splits at the one that opens the node Concurrent splits of one place fold into one (dealias), and the first run in document order opened the node. But a character typed at the end of the left node by someone who did not know a split sits after that split in the token order, with an earlier ticket. So it moved right and took the other side's style: A splits "a|b", bolds "b" and types "x" after "a" while B splits "a|b" too; A saw "ax | b(bold)", the merge showed "a | xb(bold)". With a split of "a|x" in between, "b" joined the "x" node and took its style. The opening run is now the first one followed, past the other runs of its key, by the token right of the place, by a later token (typed into the split's node) or by nothing (foldReps); the first run when none is. The runs before it open nothing either. Their ids join it, and so does what was written on their node. What a range write gave them, because they lay in its range, goes to the node open where they stand, which holds the characters after them: a register entry now records that a range write gave it (ZeroAttrEntry.by_range), and a split copy drops the mark. An insertion before a view token goes before the folded split markers right in front of it (insertPos): after one, it would read as typed into the node that split opens and could make it open the node. Only markers of a boundary split more than once are skipped. The range fuzz no longer counts characters next to folded markers apart: any character a format did not cover that gets its key fails it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | 2ae450b | |
|---|---|---|
| Author: | jinho.park.s3 | |
End a ZeroTree range format at the node's last character A range style write went from the node's marker to the token that ended the node in its author's view. Someone formatting the next characters at the same time splits at the same place, and their split marker sits between the node's last character and that token. So it got the write, and the next characters took the format too: A bolds [0,1) of "abc" while B underlines [1,3), and "bc" ended bold and underlined. The range now ends at the last character of the node in its author's view (ZeroStyleRange.last, which takes the place of until). A marker after it opens what follows the range, a format of the next characters or an Enter at the node's end, and does not get the write. The token order between two tokens never changes, so whether a marker falls in the range does not depend on when anything arrives. A pending range write keeps its end under "l". A node without characters gets a plain write. The range fuzz now also formats abutting ranges on two replicas at once, and checks that no character of the paragraph a format did not cover gets its key. A character next to a folded marker with something between it and the split it was folded into (a character typed there, another split) is counted apart: it joins whatever node is open there or takes the folded marker's registers, a structure of dealias that predates range writes. A register whose kept writes are all cancelled falls back to what the oldest one's marker held before it. That value now carries the initial ticket rather than the oldest write's: it predates every write the register keeps, so a value it meets when dealias merges a folded marker's registers, or in a copy, wins over it. An undone format no longer takes a character's style from a concurrent split it was folded with. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | f9607a3 | |
|---|---|---|
| Author: | jinho.park.s3 | |
Undo a ZeroTree format by cancelling its write An undo of a style write wrote the marker's previous value back with a new ticket, on every marker of the write's range. So it also took back what someone else wrote there after the format (A formats [1,8) blue, B greens [3,5), A undoes: all red), or concurrently and lost to it. A register of a non-reserved key now keeps its newest writes (ZeroAttr.history, at most 4, newest first). The reverse of a style write is no longer a write: it cancels the write's ticket in a table of the tree (ZeroStyleCancel, LWW by the undo's ticket), and every register keeping the write takes the newest write not cancelled again. A redo brings the write back the same way, so it shows again only where it is still the newest. When every kept write of a register is cancelled, the register falls back to what the write's own marker held before it. Reserved keys (zt.*) stay plain registers and are still written back. The kept writes only grow (a top-k by ticket) and the table is LWW per write, so the order changes arrive in does not matter. Registers keep their writes through split copies, range writes, concurrent markers and snapshots; a copy drops the writes already undone, and a marker inserted or restored takes its value under the table. A tree indexes which tokens keep each write, so an undo repicks only them and the block index recomputes only their blocks. A table entry is a GC pair of the tree: it goes once every replica knows it and no register keeps the write (its range write no longer pending either). An undo of a format also removes the splits the format put in. When someone else has written on one of those markers since, the undoer now keeps them (keepWrittenSplits): their characters would otherwise join the node before and lose what was written. proto: ZeroAttr.history (ZeroAttrEntry), ZeroTreeStyle.cancel and ZeroTree.style_cancels (ZeroStyleCancel). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | 391c874 | |
|---|---|---|
| Author: | jinho.park.s3 | |
Carry the range of a ZeroTree style write as a field The range rode along the writes as a reserved key (zt.until). It is now ZeroTreeStyle.range, a ZeroStyleRange whose until is the token that ended the node in its author's view (absent: to the end of the document); a write without it stays a write on one marker. The pending range writes stay registers of their start marker (zt.r.<ticket>): the marker attributes already travel in snapshots and survive node splits, ghost purges, copies and revivals in both SDKs. A marker inserted concurrently with several pending writes gets them in ticket order, as the Go server does: the values do not depend on it, but the order a marker first gets its keys in is part of its encoding. The range fuzz checks that no zt.* key reaches the model or an event, and can export its cases for the Go cross-SDK test. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | fa244cb | |
|---|---|---|
| Author: | jinho.park.s3 | |
Add ZeroTree, a flat-token data type for the Zero editor (prototype) Tree splits and merges for a block editor keep diverging under concurrent Enter, because each replica decides at apply time how a split relates to the tree it sees. ZeroTree stores a Zero document as one flat token sequence in RGATreeSplit: an open marker per element (type, depth, LWW attributes) followed by its characters. Enter is one insertion of a marker run, a merge removes one marker, and a style is a LWW write on a marker. The editor model is a pure function of the live tokens, so concurrent Enter reduces to concurrent insertion at one place and nothing is decided at apply time. - crdt/zero_tree.ts and zero_tree_view.ts: the element, its tokens and the model built from live tokens (buildView, dealias), with the schema kept in the element. - json/zero_tree.ts and operation/zero_tree_operation.ts: Zero operations (insert, delete, split, merge, update) compiled to token edits and marker styles, with identity-preserving undo and redo on top of the Text removal ledger. - GC keeps a purged node in place as a ghost: only its characters go, so an undo after GC revives it where an uncollected replica has its tombstone and positions anchored on it still resolve. - Protobuf: VALUE_TYPE_ZERO_TREE, ZeroTree element with an actor table, ZeroTreeEdit and ZeroTreeStyle operations. - Schema: yorkie.ZeroTree in the schema language and ruleset validator. This is a prototype for discussion: comments marked PROTOTYPE remain, and the Zero-specific parts (schema shape, grid columns) are not meant as a general API. See docs/design/zero-tree.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | 0e3bb51 | |
|---|---|---|
| Author: | jinho.park.s3 | |
Keep a Text removal the undo never saw An identity-preserving undo of a Text deletion cleared the tombstone outright, so it also revived text that a concurrent deletion it never saw had removed: from abcdefgh, B deletes d and undoes it while A deletes defgh, and A ends with abcd and B with abc depending on delivery order. The reverse case is yorkie#2237: a remote deletion removed every node whose creation it knew, including one the deleter saw removed and an undo revived here, so d1 kept efh while d2 lost f again. Each RGATreeSplitNode now keeps a removal ledger: the deletions that removed it while it was live in the deleter's view, and the undos that cancelled some of them. removedAt stays the latest uncancelled deletion, so a node no undo touched looks exactly as before. - A restore span carries removedBy, the deletion it undoes, and the restore cancels only that one. A redo records a new deletion, and the next undo names the redo. - A remote deletion removes only nodes live in the deleter's view. A node it saw live but someone else removed records the deletion anyway, so a later undo of the other deletion keeps it removed in every order. - GC keeps what a purged piece's ledger still said. A restore that finds the piece gone recreates only what no other deletion holds, piece by piece, as an unpurged replica would. - Ledgers and purged ledgers travel in snapshots, and removed_by on the wire. A server re-encodes the pack and drops fields it does not know, so removedBy is sent only while the server advertises the new restore-removed-by capability. Without it an undo drops removedBy and revives the span as every replica did before. Part of yorkie-team/yorkie#2237 (the Text half; Tree has its own path). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| Commit: | c1a0387 | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | GitHub | |
Ask the server for Watch heartbeats at a chosen interval (#1483) yorkie#2209 made the Watch heartbeat opt-in per stream: WatchRequest carries heartbeat_interval_ms, and the server clamps it into its bounds and advertises the effective value. This SDK never asked, so the idle watchdog from #1472 could not arm against a server that leaves heartbeats on for older clients. The client now asks for a heartbeat on both the document and the channel Watch request through ClientOptions.watchHeartbeatInterval, 20 seconds by default. Zero, a negative value or NaN asks for none, a fraction rounds up so the server clamps it instead of opting out, and a value past int64 is capped so serialization cannot fail. The proto is synced from yorkie#2209, and the heartbeat integration cases skip on a server that does not support the field. Closes #1479
| Commit: | c69e6bd | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Reconnect a Watch stream that goes silent past the server heartbeat (#1472) A quiet document sends nothing on its Watch stream, so a half-open connection -- a laptop resuming from sleep, a network change, a proxy dropping an idle socket without a reset -- looked exactly like a quiet document: the stream stayed "connected" while the document froze. Server v0.7.25 can heartbeat idle streams and advertises the interval in the init response; the protos are synced with Go to read it. When the interval is non-zero, runWatchStream now treats three intervals of silence (clamped to [1s, 24h], as in the Go client) as half-open: it aborts the stream, reports ErrWatchStreamIdle and reconnects from the timer itself, ignoring the abandoned stream, because over Node's fetch an aborted read on a half-open socket never settles. A stream the client aborted is never reported as idle. An interval of 0, which older servers and the default config send, keeps today's behavior. The unbounded wait for a reconnect's init response is tracked as #1473. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
| Commit: | d3ffe94 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Sync the protos with Go and harden crafted tree payloads (#1406) Closes two Go/JS parity gaps; Go is the source of truth for the wire format and tree semantics. The .proto files are byte-identical to yorkie main again (73139d01) and the bindings are regenerated: ChangePack.capabilities, restore_mode on Set/Add/ArraySet, revived_at on every JSONElement, and the project's channel_session_ttl. The new fields are dormant; no converter reads or writes them yet. Every merge pointer now resolves to the exact element it names (yorkie#2033). A mergedFrom survives on an element payload, so a client can supply both ends of a merge relation, and five readers still resolved those pointers with a floor lookup. They now go through findMergeNode, and rebuildMergeState skips a child of a text node as Go does; the insert redirect could otherwise hand back a text node as the parent and every later edit through it threw. TreeEdit content is stripped of engine-only state on decode, matching Go: an empty content group is rejected instead of crashing on apply, insert and merge links are dropped, and tombstones are cleared post-order so ancestor sizes are restored. The local copy-reinsert undo path already cleared the same fields, so authoring and receiving replicas agree. The SDK test scripts also wait for the server's health RPC before the integration suites, which used to race a container that had started but was not yet serving. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
| Commit: | f3303a5 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Sync the protos with yorkie and regenerate the bindings The JS copies of resources.proto and yorkie.proto lagged yorkie's, which is the source of truth for the wire format. yorkie 73139d01 added the element-restore wire fields (ChangePack.capabilities, restore_mode on Set/Add/ArraySet, revived_at on every JSONElement subtype) and channel_session_ttl on the project messages, along with comments. Both files are now byte-identical to yorkie's and the bindings are regenerated with buf. The new fields are dormant: no yorkie converter reads or writes them yet, so the JS converter does not either. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
| Commit: | 2291bf6 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add offline local persistence (serialize, store, resume, multi-tab) (#1338) Persist a document and its un-pushed local changes to a pluggable DocStore, and resume them on the next session: serialize via doc.toBytes()/fromBytes, restore on attach, and present the persisted checkpoint/epoch so the server re-accepts the re-pushed changes. A single-active-session lease (Web Locks by default) guards multi-tab use. Consumes the server stable actor (ActivateClientResponse.actor_id) as the document actor and declares it on the watch stream so presence peers stay aligned; on an offline force-compaction the resume re-anchors from a snapshot and surfaces a LocalChangesDropped data-loss event. Requires a server with offline-resumable attach and watch stable-actor support (yorkie-team/yorkie#1969, #1970). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
| Commit: | 1901792 | |
|---|---|---|
| Author: | hackerwins | |
Declare the stable actor to the watch stream Presence is keyed by the actor stamped into changes (the stable actor for opted-in clients), but the watch stream identified peers only by the session client id. On a server that returns a distinct stable actor the two identity spaces diverged, so remote peers' presence became invisible and watched/unwatched events no longer matched. Send the stable actor as WatchRequest.actor_id so the server can subscribe the client under the same actor its presence changes carry. The field is additive; old servers ignore it and old SDKs omit it, falling back to the session id. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
| Commit: | d1ad8c9 | |
|---|---|---|
| Author: | hackerwins | |
Add epoch field to ChangePack proto and regenerate The server added `int64 epoch = 8` to ChangePack as a bidirectional carrier: responses report the document's current compaction epoch and a resume attach seeds the client's epoch from the presented value. Mirror that field in the vendored proto so the SDK can present and learn it. The generated diff is limited to the resources_pb.ts ChangePack epoch field and the schema descriptor, matching how earlier proto syncs kept the change scoped to resources.proto plus its generated output. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
| Commit: | 0830cb2 | |
|---|---|---|
| Author: | hackerwins | |
Stamp the stable actor into document changes ActivateClient now returns a stable actor_id. Adopt it as the document actor (doc.setActor) while every RPC keeps using the per-session client id for row lookups. Fall back to client_id against servers that do not return actor_id, so old servers are unaffected. Sync the vendored proto and regenerate the generated client. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
| Commit: | 4ec66cc | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Stop undo and element splits from reusing a node's identity (#1319) A CRDTTreeNodeID must name a single node. #1318 made the tree survive two nodes claiming one; this removes the two paths in this SDK that create them. A reverse that reverses a deletion by re-inserting a copy of the removed nodes carried their original IDs, so undoing put two nodes under one — and since the server now drops content that reuses an identity, those undos silently did nothing. The copy takes fresh tickets at undo time now, from the change the undo creates, where ArraySet and Add already re-identify a restored value. Restore-mode reverses keep their identity, which is what makes concurrent undos of one deletion converge. A fresh identity has to be fresh in every field that names a node: the copy comes from a deepcopy carrying the split chain and merge lineage of the node it copied, and leaving those would splice it into a chain it never belonged to, where purge relinking would unlink the real tombstone. The tickets an element split consumes were reconstructed from executedAt and the number of top-level contents, which under-counts as soon as content has descendants — each of those took a ticket too — so a split ticket could land on an ID the edit's own content already held. The operation now carries what the originating replica issued. A change written before the field exists falls back to the reconstruction, so stored histories replay unchanged. The rules that decide which node an ID names have to hold on both sides of the wire, so the split tickets land with yorkie-team/yorkie#1929 rather than after it.
| Commit: | 3c4331f | |
|---|---|---|
| Author: | Youngteac Hong | |
Carry the tickets an element split issued in the operation Mirrors yorkie's side of the same change. The tickets an element split consumes were reconstructed by every replica from executedAt and the number of top-level contents, which cannot be right: content nodes take a ticket each, descendants included. A split ticket could therefore land on an id the edit's own content already held — two nodes under one CRDTTreeNodeID, reached by ordinary editing. The originating replica now records what it issued and the operation carries it, so neither side depends on the other's allocation staying in step. A change written before the field exists carries none and falls back to the reconstruction, so stored histories replay unchanged. The rules that decide which node an id names have to hold on both sides of the wire, so this lands with the server change rather than after it.
| Commit: | fa6cc51 | |
|---|---|---|
| Author: | harrykim8672 | |
| Committer: | GitHub | |
Add identity-preserving restore for Tree undo/redo (#1297) Undo of a Tree deletion re-inserted fresh copies of the deleted nodes and reconciled them by index. The copies were different nodes from the originals, so a replica applying the undo alongside a concurrent edit could not agree with one that applied them in the other order. Revive the original nodes by identity (createdAt + offset) instead, and re-tombstone them on redo. This is the client half of the change; the server side landed in yorkie-team/yorkie#1893, which executes the same ops so its snapshots track clients. Wire: add a TreeRestoreSpan message plus restore_spans, restore_mode and retombstone_spans on Operation.TreeEdit, reusing the RestoreMode enum. A tree span carries the node's structure and its position anchors, not just a flat offset, because id order is not sibling order in a tree. CRDTTree: add restore(), retombstone(), findPiecesOverlapping() and recreateFromSpan() for a node the GC already purged. Placement walks an anchor ladder -- same-insertion text neighbour, then the carried left or right boundary sibling, then a deterministic id-order fallback that is a pure function of ids and so resolves identically on every replica -- and skips the node when its parent is genuinely gone. Reverse ops: toReverseOperation now emits spans and leaves `contents` undefined on that path, and edit() fills the spans only when the edit was merge/split-free. Inserted spans are reversed before they are attached so parents precede children, which is the order restore() needs to rebuild a purged subtree top-down. Decoding rejects a malformed span rather than letting it through: every node id needs a created_at and every attribute an updated_at, because fromTreeNodeID and fromRHT non-null assert those tickets and would otherwise yield an undefined timestamp that only fails deep in the restore path. Scope, matching the Text feature: pure deletion and insertion undo. Merge/split reverses keep the copy-reinsert path, and there is no delete-ownership gating, so an undo revives content a concurrent delete by another actor still holds removed. Tests cover the wire round trip and its malformed-input rejections, and restate the reverse-op regression suite against the span payload, since `contents` is empty by design now. The payload must describe only the nodes the reversed edit touched -- never ones tombstoned beforehand -- with stable identities across redo cycles. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
| Commit: | 5d5cac6 | |
|---|---|---|
| Author: | harrykim8672 | |
| Committer: | GitHub | |
Identity-preserving restore for Text undo/redo (#1293) Overlapping undo of Text deletions duplicated the shared content: each client's undo deep-copied the removed text and re-inserted it as new CRDT nodes, so two clients undoing overlapping deletes both re-created the shared characters ("012345674589" instead of "0123456789"). Carry the removed content tagged with its split-invariant character identities (original insertion createdAt plus absolute offset) so restore re-establishes those exact nodes: a live piece is skipped, a tombstoned piece is un-tombstoned, and a GC-purged piece is recreated under its original ID. Overlapping undos become an order-independent set union, and carrying the content keeps restore GC-safe. Add restore/retombstone primitives to the CRDT layer, route pure-deletion undo/redo through them in EditOperation, and add the RestoreSpan message and RestoreMode enum with converter passthrough so the payload survives the server round-trip. Companion to yorkie-team/yorkie#1875. Text only; Tree and replace-edit undo remain follow-ups. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
| Commit: | 2355936 | |
|---|---|---|
| Author: | JiHwan Yim | |
| Committer: | GitHub | |
Add disablePresence option for presence-free Documents (#1285) Adds `disablePresence?: boolean` to `DocumentOptions` and `AttachOptions` so a Document can opt out of producing, consuming, or storing presence. The flag is sent on `AttachDocumentRequest`, fixated server-side on first attach (paired with yorkie-team/yorkie#1841), and read back from the response so late attachers learn the persisted value. When the resolved value is true, `client.attach` skips the initial presence push and `Document.update` silently drops any presence emit from the user callback (`ChangeContext.dropPresenceChange` + `clearReversePresence`), warning once per Document instance. A change carrying no operations after the strip never enqueues. `DocumentProvider` accepts the prop and threads it through `useYorkieDoc` into both `new Document` and `client.attach`, redepping on the value so a flipped prop spawns a fresh Document. Unit and integration tests cover local gating and the server-fixated strip across clients.
| Commit: | 63afb29 | |
|---|---|---|
| Author: | hackerwins | |
deploy: 1a919e142e2377277ef8330bf5526a570a10e4a7
This commit does not contain any .proto files.
| Commit: | 4500c4f | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add disableGC attach option (#1265) Mirrors the wire contract from yorkie-team/yorkie#1822. Surfaces a disableGC attach option so a client can opt out of receiving the response VersionVector and participating in server-side minVV tracking. Targets high-fan-out Counter or primitive workloads where no client consumes tombstones. await client.attach(doc, { disableGC: true }); Adds bool disable_gc to AttachDocumentRequest (field 4) and PushPullChangesRequest (field 5) in the SDK's proto. Stores disableGC on the per-document Attachment so every subsequent PushPullChanges carries the flag, matching the server's per-request reading. The SDK option controls only the wire contract. It is distinct from any local-only Document GC pass. Misuse on a document that uses Tree, Text, or Array deletions leads to undefined GC behavior on this client; this is documented on the option's JSDoc.
| Commit: | c92a34f | |
|---|---|---|
| Author: | JOOHOJANG | |
| Committer: | GitHub | |
Channel lifecycle via RefreshChannel only (#1258) Align the JS SDK with the yorkie server change that folded ActivateClient, AttachChannel, and RefreshChannel into a single RefreshChannel call. The first call carries client_key and metadata, and the response delivers the assigned client_id and session_id. Drop the AttachChannel and DetachChannel RPC calls and route channel attach/detach through RefreshChannel only. Allow client.attach(channel) and peekChannel without a prior client.activate(); channel-only clients are activated lazily by the first heartbeat. Defer opening the Realtime watch stream until the first heartbeat populates client.id, which the watch RPC requires. Default the channel heartbeat to 5s (TTL/3 for the server's new 15s ChannelSessionTTL); document polling default stays at 3s. Auto-recover when the server returns ErrSessionNotFound by clearing the local sessionID so the next tick transparently re-attaches. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
| Commit: | 8cd527e | |
|---|---|---|
| Author: | JOOHOJANG | |
| Committer: | GitHub | |
Add PeekChannel client + usePeekChannel React hook (#1256) Pairs with yorkie-team/yorkie#1805. Exposes the new server-side PeekChannel RPC as `client.peekChannel(channelKey): Promise<number>` and a `usePeekChannel(channelKey, opts)` React hook on top of it. PeekChannel reads a channel's session_count without creating a Session on the server, without subscribing to broadcasts, and without paying pubsub fan-out cost. Use it for read-only displays of the count (e.g. an "N writing" badge shown on many surrounding pages) where ChannelProvider(readOnly) would have every viewer occupy a Session. The hook supports one-shot fetch (default), continuous polling via pollInterval, an enabled flag, and an imperative refetch(). The SDK method is serialised through the client task queue so concurrent calls cannot race deactivate(). The hook tracks mount state so refetch() after unmount no longer leaks setState calls. A polling playground demo (StockDetail WritersPeekCTA, WritePostPage) shows the recommended usage pattern. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
| Commit: | 045a227 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Apply array-move-convergence with LWW position register (#1227) Port the LWW position register design from the Go SDK to fix Array.MoveAfter non-convergence. Core changes: - Separate element identity from position with ElementEntry and RGATreeListNode (matching Go SDK structure) - MoveAfter with LWW check, dead position node creation for losers - Register dead position nodes for GC in all local move paths (moveBeforeInternal, moveAfterInternal, moveFrontInternal, moveLastInternal) - Convert element identity to position identity at insert call sites (insertAfter proxy, insertIntegerAfterInternal, splice) - Remove getPrevCreatedAt legacy fallback, delegate to findPrevCreatedAt - DeepCopy preserves dead position nodes and posMovedAt metadata - Snapshot serialization with position_created_at, position_moved_at, position_removed_at fields - Skip set-after-move undo tests (requires proto-level fix) Tests: - Array Concurrency Table: 49 op-pair cases - Complicated concurrent array operations: 4 double-move cases Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
| Commit: | 8a2b55b | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add Counter dedup mode with HyperLogLog for UV measurement (#1215) Add a dedup Counter variant (IntDedup) that uses HyperLogLog to count unique actors, matching the Go server implementation. Key changes: - HyperLogLog with xxhash64 (pure BigInt, zero dependencies) — produces identical output to Go's cespare/xxhash/v2 - New CounterType.IntDedup encodes dedup mode at creation - DedupCounter class with add(actor) API for clean usage - IncreaseOperation carries optional actor field, disables undo/redo for dedup (HLL is append-only) - Dedup Counter blocks plain increase(), enforces delta == 1, validates actor, masks BigInt shift to 64 bits - HLL state serialized in snapshots, restore validates payload size Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
| Commit: | bb112b8 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Mirror tree merge snapshot encoding fix from Go SDK (#1210) Port yorkie-team/yorkie#1729 to keep JS clients consistent with the server's new snapshot encoding for merge runtime state. Without this, a JS replica attaching after a remote merge and receiving a concurrent insert targeting the merged-away parent would silently drop the insert. Add merged_from (#9) and merged_at (#10) optional fields to the TreeNode proto; regenerate resources_pb.ts (yorkie_pb.ts also rides along, picking up pre-existing source drift). toTreeNodes writes both fields; fromTreeNode reads them. CRDTTree gains a rebuildMergeState pass called from the constructor, reconstructing mergedInto on source parents from the moved children's mergedFrom and falling back to source.removedAt for mergedAt on pre-fix snapshots. CRDTTreeNode drops mergedChildIDs entirely; its two use sites (propagateMergeDeletes and the redirect branch in findTreeNodesWithSplitText) now recompute the list via mergeTarget.allChildren filtered by mergedFrom. Final merge- field count on CRDTTreeNode: 4 -> 3, matching Go. See yorkie-team/yorkie#1729 for the full rationale, including the review that caught the source.removedAt mutability issue. Verified by a new converter_test.ts regression, 237 unit tests, and 141 + 1128 integration cases across tree_test.ts and tree_concurrency_test.ts. Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
| Commit: | 95fcdb6 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add tree-level schema validation and ProseMirror example (#1181) Implement ProseMirror-compatible content expression system to validate CRDTTree structure against schema-defined node rules. This enables defining tree node types with content expressions, marks, and groups directly in the Yorkie schema DSL (e.g. yorkie.Tree<{ doc: { content: "paragraph+"; }; }>). Changes: - Extend ANTLR grammar and RulesetBuilder to parse tree schema definitions - Implement content expression parser/matcher with backtracking support - Add tree validator that checks node types, content rules, and marks - Integrate tree schema validation into the ruleset validator pipeline - Add protobuf TreeNodeRule support and API converter - Add ProseMirror tree-schema example with setup script - Add comprehensive unit and integration tests Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
| Commit: | 994bae2 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add undo/redo support for Text.Style operations (#1174) Add reverse operation construction to StyleOperation.execute() so that text style changes can be undone and redone. This follows the existing TreeStyleOperation pattern with attributesToRemove for style removal. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
| Commit: | 8013490 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Replace WatchDocument and WatchChannel with unified Watch RPC (#1161) Update JS SDK to use the unified Watch RPC instead of the removed WatchDocument and WatchChannel RPCs. Split Document.applyWatchStream into applyWatchInit and applyDocEvent methods for cleaner separation of initialization and event handling. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
| Commit: | fb8eb1c | |
|---|---|---|
| Author: | emplam27 | |
| Committer: | GitHub | |
Refactor channel terminology from presence to session (#1154) Rename the term "presence" to "session" across channel logic. Update Protobuf field name from "count" to "session_count" in channel API responses.
| Commit: | 244a37f | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Remove RemoveIfNotAttached option from SDK (#1148) The option is now managed at the project level and has been removed from the SDK. For more details: https://github.com/yorkie-team/yorkie/pull/1622
| Commit: | 4e1896b | |
|---|---|---|
| Author: | emplam27 | |
| Committer: | GitHub | |
Rename presence_count to session_count (#1142)
| Commit: | b0f363e | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add GetRevision for retrieving specific revisions (#1133)
| Commit: | fe1dbc2 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Implement revision management (#1127) Introduce full revision management for documents, including creation, paginated listing, and restore operations with labels and descriptions.
| Commit: | 2d5fb05 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Update CHANGELOG.md for v0.6.39 (#1125)
| Commit: | 3ba4f37 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Rename Presence to Channel (#1103) This commit refactored Presence to a more general-purpose Channel. The new Channel abstraction supports both presence tracking and message broadcasting within the same interface. All presence-related RPC methods have been renamed to their channel-based counterparts: AttachChannel, DetachChannel, RefreshChannel, and WatchChannel. Request and response message types have been updated to align with the channel architecture, and a new ChannelEvent type was introduced for unified event streaming and management. This change introduces breaking updates—existing integrations using Presence must migrate to the new Channel APIs.
| Commit: | ed6476f | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Refactor broadcast handling in Presence (#1102) This commit refactored the broadcast system to use Presence as the primary communication channel instead of Document. PresenceEvent now supports broadcast events with publisher, topic, and payload details. It also removed document-based broadcast logic and updated request structures to use presence keys rather than document identifiers.
| Commit: | 2f909f2 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Enhance presence with manual and realtime sync (#1096) - Modified `refreshPresence` to return presence count.
| Commit: | 6b78c18 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add real-time presence tracking (#1091) This commit introduces real-time presence tracking in the JS SDK, allowing clients to attach, detach, refresh, and watch presence states with live count updates and heartbeat-based session management. A unified attach/detach model has been added for both documents and presence, based on the new Attachable and Attachment resource model. The SDK now exposes presence events (initialized, count-changed), configurable heartbeat intervals, and a demo page showing join/leave and online counts. The document-level presence type has been renamed from Presence to DocPresence, and Presence is now exported from the top-level API.
| Commit: | f14b06e | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Introduce Dedicated Presence
| Commit: | 46d1148 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Introduce presence counter
| Commit: | 36e35d6 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Introduce presence counter
| Commit: | 35fc014 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Introduce presence counter
| Commit: | 6435b07 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Add getOthersPresences and synchronous deactivation (#1081) This commit introduces the doc.getOthersPresences() API, which allows retrieving the presences of other collaborators in a document while excluding the caller’s own presence. In addition, a synchronous option has been added to client deactivation to support cases where a synchronous shutdown flow is required. This commit also reflects recent Admin API changes.
| Commit: | 88f853e | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Remove deprecated SelectOperation (#1038) SelectOperation in Text is no longer needed since presence is now handled via Change. It was kept for backward compatibility, but has become obsolete after document compaction. This commit removes it completely.
| Commit: | c4890e7 | |
|---|---|---|
| Author: | Youngteac Hong | |
Revise the codes
| Commit: | 6b78d99 | |
|---|---|---|
| Author: | yonguk-k | |
Add clientKey field to yorkie API requests for clients collection key-wide hashed sharding
| Commit: | 938838c | |
|---|---|---|
| Author: | yonguk-k | |
Add client_key field to multiple request messages in API
| Commit: | 9774951 | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | GitHub | |
Add schema support (#1010) This commit introduces schema support to validate and manage the structure of collaborative documents. Schemas can be created and updated via the dashboard UI, and are stored and validated using the @yorkie-js/schema package. A schema can be attached to a document using the SDK before any clients are attached. If a schema is already attached or the document has active clients, the attachment is ignored. During local edits, the attached schema is used to validate changes, and schema violations result in client-side errors. Via the AdminService API, schemas can also be updated or detached from documents. The UpdateDocument API supports different behaviors depending on whether the `root` and `schemaKey` fields are present or empty. Currently, only primitive type validations are supported. Additional rule types will be implemented later in the ruleset generation and validation logic.
| Commit: | 616e468 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Bump up presence protocol (#1008)
| Commit: | 5dd44fe | |
|---|---|---|
| Author: | Yourim Cha | |
Update proto
| Commit: | 34df77b | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | Yourim Cha | |
Move schema rules from ChangePack to AttachResponse
| Commit: | fa59385 | |
|---|---|---|
| Author: | Yourim Cha | |
Merge branch 'main' of https://github.com/yorkie-team/yorkie-js-sdk into schema
| Commit: | 8e4251a | |
|---|---|---|
| Author: | JiHwan Yim | |
| Committer: | GitHub | |
Introduce size limit for documents (#992) Added size limit for documents(10 MiB default), enforced during the document editing. Local updates will be checked against this limit, but remote changes exceeding the limit will still be accepted. This helps prevent excessive resource usage and ensures stable client-server interactions.
| Commit: | 1cf121d | |
|---|---|---|
| Author: | raararaara | |
Add test for document size limit
| Commit: | dff5b14 | |
|---|---|---|
| Author: | raararaara | |
Introduce doc size limit
| Commit: | 52fa09a | |
|---|---|---|
| Author: | Yourim Cha | |
Merge branch 'main' of https://github.com/yorkie-team/yorkie-js-sdk into schema
| Commit: | 45c9d3d | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | GitHub | |
Remove deprecated MinSyncedTicket and MaxCreatedAtMapByActor (#969) This commit removes legacy fields and logic related to Lamport timestamp synchronization: - Removed `MinSyncedTicket` and its associated logic - Removed `MaxCreatedAtMapByActor` and related code These were previously retained for backward compatibility during the migration to VersionVectors and are no longer needed.
| Commit: | 1a2bb22 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Add schema support
| Commit: | 6a2351f | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Add schema support
| Commit: | 14e0fc2 | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | Yourim Cha | |
Removed the deprecated MaxCreatedAtMapByActor field and its associated logic
| Commit: | 59661f3 | |
|---|---|---|
| Author: | Yourim Cha | |
Remove deprecated MinSyncedTicket field and related functionality
| Commit: | a2c785c | |
|---|---|---|
| Author: | emplam27 | |
| Committer: | GitHub | |
Add metadata to Client for MAU tracking (#942) Enhances client information tracking by adding metadata fields. These additions enable accurate Monthly Active User measurements and allow for storage of additional user-specific data in the analytics system.
| Commit: | 2124689 | |
|---|---|---|
| Author: | JOOHOJANG | |
| Committer: | GitHub | |
Introducing version vector to solve GC problem (#899) This change introduces Lamport Synced Version Vector to resolve defects in the existing garbage collection system that used syncedSeq. Key improvements include: - Added Version Vector implementation with Lamport timestamp support - Implemented database storage and update mechanisms for version vectors - Created min version vector computation for safe garbage collection - Added handling for detached client's version vectors to prevent memory leaks - Updated change ID generation to incorporate version vector information The Version Vector ensures all changes are properly synchronized across replicas before garbage collection occurs, improving system reliability and reducing memory waste from detached clients. --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>
| Commit: | cdeeef7 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Update target to ES2020 and replace Long with bigint (#912) This commit Streamlines data type handling by replacing Long with native. It also updates target to ECMAScript 2020. Despite the introduction of bigint, but Long still remains in Counter. We need to remove Long.
| Commit: | ee8e411 | |
|---|---|---|
| Author: | JOOHOJANG | |
Remove min synced version vector from proto
| Commit: | cae3f9c | |
|---|---|---|
| Author: | JOOHOJANG | |
Remove snapshot version vector
| Commit: | e0988d0 | |
|---|---|---|
| Author: | JOOHOJANG | |
Update Proto
| Commit: | 6f0c315 | |
|---|---|---|
| Author: | JOOHOJANG | |
Build proto to reflect versionvector and min synced version vector
| Commit: | 2f1cd8b | |
|---|---|---|
| Author: | Gunwoo Baik | |
| Committer: | Youngteac Hong | |
Introduce monorepo to manage packages using `pnpm` (#880) Workspace: ``` examples/ - nextjs-scheduler - profile-stack - react-tldraw - react-todomvc - simultaneous-cursors - vanilla-codemirror6 - vanilla-quill - vuejs-kanban packages/ - create-yorkie-app - devtools - sdk <-- previous yorkie-js-sdk package ``` Command: ``` `sdk` - [x] pnpm sdk build - [x] pnpm sdk build:proto - [x] pnpm sdk build:docs - [x] pnpm sdk build:ghpages - [x] pnpm sdk dev - [x] pnpm sdk test - [x] pnpm sdk test:watch - [x] pnpm sdk test:bench - [x] pnpm sdk test:ci - [x] pnpm sdk test:yorkie.dev - [x] pnpm sdk lint - [x] pnpm sdk prepare `devtools` - [x] pnpm devtools dev - [x] pnpm devtools build - [x] pnpm devtools test `create-yorkie-app` - [x] pnpm create-yorkie-app start - [x] pnpm create-yorkie-app build - [x] pnpm create-yorkie-app build:copy-assets ``` --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>
| Commit: | ef412fa | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Introduce VersionVector
| Commit: | 9e12b9e | |
|---|---|---|
| Author: | JiHwan Yim | |
| Committer: | GitHub | |
Add RHTNode removal to converter for consistency (#842) This commit addresses the missing `isRemoved` encoding in the RHT. Similar to other CRDTs like ElementRHT, including tombstone nodes like `isRemoved` during encoding is crucial. However, the RHT did not include tombstone nodes in its encoding, leading to inconsistencies in snapshots. --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>
| Commit: | e086ad7 | |
|---|---|---|
| Author: | JiHwan Yim | |
| Committer: | GitHub | |
Handle concurrent editing and styling in Tree (#803) We will use maxCreatedAtMapByActor until the introduction of VersionVector.
| Commit: | 2af8a0c | |
|---|---|---|
| Author: | JiHwan Yim | |
| Committer: | GitHub | |
Implement Protocol Changes for Tree.RemoveStyle (#755) This commit reflects protocol changes for the Tree.RemoveStyle. Proto file and converter were modified to reflect requirements related to the Tree.RemoveStyle patch.
| Commit: | 2882578 | |
|---|---|---|
| Author: | Sejong Kim | |
| Committer: | GitHub | |
Restore interface changes due to server DB sharding (#740) This commit restores passing sharding keys to the SDK in accordance with yorkie-team/yorkie#776.
| Commit: | 363229b | |
|---|---|---|
| Author: | Sejong Kim | |
| Committer: | GitHub | |
Reflect interface changes of server DB sharding (#726) This commit reflects passing sharding keys to the SDK in advance before releasing the server with MongoDB sharding applied.
| Commit: | 7368454 | |
|---|---|---|
| Author: | Kevin Park | |
| Committer: | Youngteac Hong | |
Migrate RPC to ConnectRPC (#698) With this support, we can resolve several issues: - Removes dependency with Envoy proxy to communicate with grpc-web - Reduces SDK bundle size by half bundle size of #434 - Standardizes API interfaces to powerful fetch API For more information about this migration, follow: yorkie#703 --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>
| Commit: | 6e8150c | |
|---|---|---|
| Author: | Kevin Park | |
Set connect-es js import style to commonjs & enable benchmark
| Commit: | 2b52110 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | Youngteac Hong | |
Clean up yorkie.proto and remove grpc-web from package.json
| Commit: | 4cc4c10 | |
|---|---|---|
| Author: | Kevin Park | |
| Committer: | Kevin Park | |
Update client runWatchLoop to avoid async promise executor
| Commit: | 1280b13 | |
|---|---|---|
| Author: | Kevin Park | |
| Committer: | Kevin Park | |
Update protobuf and client
| Commit: | 2b0b7f6 | |
|---|---|---|
| Author: | Youngteac Hong | |
| Committer: | GitHub | |
Implement splitLevel of Tree.Edit (#704) When a user positions the cursor within a paragraph and hits the enter key, the paragraph is divided into two separate paragraphs: - Original: `<p>a|b</p>` - Result: `<p>a</p><p>b</p>` In this commit, `splitLevel` is introduced to support this scenario. ```ts doc.update((root) => { root.tree.edit([0,0], {type:'p',children:[{type:'text', value: 'ab'}]}); root.tree.edit([2,2], undefined, 1); // split the paragraph }); ``` This commit does not cover all test cases that may arise due to the split operation. This is because we need to verify the interface first. we need to add test cases in the simultaneous editing situation to verify the algorithm later. Tasks: - Refactor Tree.Edit logic to implement splitLevel of Tree.Edit - Remove skip from the unit tests related to splitLevel
| Commit: | 5716e26 | |
|---|---|---|
| Author: | Yourim Cha | |
Remove createdAtMapByActor in EditReverseOperation
| Commit: | 5f9263f | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | Yourim Cha | |
Replace TextNodeIDWithLength to RGATreeSplitPos
| Commit: | d2a88c2 | |
|---|---|---|
| Author: | Yourim Cha | |
Merge branch 'feat/undo-redo-arch' of https://github.com/yorkie-team/yorkie-js-sdk into feat/text-edit-reverse
| Commit: | fd6ae03 | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | Yourim Cha | |
Merge branch 'main' of https://github.com/yorkie-team/yorkie-js-sdk into feat/undo-redo-arch
| Commit: | ce14cb0 | |
|---|---|---|
| Author: | Yourim Cha | |
| Committer: | Yourim Cha | |
Add fields markOpsBefore and markOpsAfter to TextNode in protobuf
| Commit: | 5bef0ad | |
|---|---|---|
| Author: | MoonGyu1 | |
| Committer: | MoonGyu1 | |
Add boundary type 'none' and apply lint
| Commit: | 79c4f41 | |
|---|---|---|
| Author: | MoonGyu1 | |
Update protocol
| Commit: | 4b1d850 | |
|---|---|---|
| Author: | hyemmie | |
Update protocol buffer to add EditReverse
| Commit: | 1594345 | |
|---|---|---|
| Author: | gyuwonMoon | |
| Committer: | GitHub | |
Support concurrent formatting of Text (#642) Currently, we are unable to check for concurrent cases when applying the Text.setStyle operation. This pull request introduces a map called latestCreatedAtMapByActor to track the causality between the operations of the two clients and ensures that the results converge into one.
| Commit: | 76370be | |
|---|---|---|
| Author: | hyemmie | |
Update protocol buffer
| Commit: | 5523983 | |
|---|---|---|
| Author: | JOOHOJANG | |
| Committer: | GitHub | |
Change TreeNode to have IDs instead of insPrev, insNext (#627) During the conversion, it's hard to find insPrev, insNext nodes from IDs because we can't use LLRB at that moment. Therefore, this commit changed it to keep IDs of insPrev and insNext and find the actual nodes when we need them.
| Commit: | 990a6d6 | |
|---|---|---|
| Author: | ehua | |
| Committer: | GitHub | |
Concurrent case handling for Yorkie.tree (#611) Introduced a new logical timestamp for identifying the position in local/remote editing, and ensures commutative editing in concurrent cases. This logical timestamp consists of {parentID, leftSiblingID}. This allows editing at the front of text nodes by using a reference to the parent, as well as getting rid of the local offset used to access an element node's children previously by using the leftSiblingID. --------- Co-authored-by: JOOHOJANG <jayjangjoo@gmail.com> Co-authored-by: Youngteac Hong <susukang98@gmail.com> Co-authored-by: sejongk <sepaper@naver.com> Co-authored-by: MoonGyu1 <s201801402@hufs-gsuite.kr>