yarn yjs 0.4.0
Support for custom Connectors

latest releases: 13.6.15, 13.6.14, 13.6.13...
9 years ago

0.4.0 Release

I created an abstract connector type that handles the sync process. The initial problem was that creating a new connector type is quite difficult: You have to know how operations are applied in the Yjs framework, and you have to come up with an efficient way to synchronize a user with the other users at the beginning of a session. Therefore, I came up with the following sync-models:

SyncAll Sync Method

This sync method originates from the original WebRTC connector. Everyone synchronizes with each other: Right after the connection is created, the peers exchange a state vector, and then send all the remaining Operations to the other users. After that, the connector only has to make sure that all sent operations reach all the other peers. I got feedback that this is the prefferred method to use, because there is no set-up involved. This method is totally fine and efficient for small networks, but is not well suited for a lot of users.

Master-Slave Sync Method

: Here, we have one or several master clients online that serve as the endpoint for the syncing process of the slaves. Therefore, you only have to sync once, even if there are thousands of users online. Still, operations can be published p2p (they don't have to go through the master-client). But you have to make sure that the master client(s) have a high uptime. They should not leave the session while a user syncs with it.

Don't miss a new yjs release

NewReleases is sending notifications on new releases.