OctoBase icon indicating copy to clipboard operation
OctoBase copied to clipboard

Why send all data for a workspace to remote after applying changes from remote?

Open videni opened this issue 9 months ago • 4 comments

Can I know why after applying changes from remote, then send all data for a workspace to remote? What if a workspace is 50MB large? I am not sure if this could happen. Just assume an embedded image encoded in the workspace underlying doc. Could you please explain a bit about the performance consideration here?

Image

videni avatar Mar 12 '25 10:03 videni

The jwst-rpc is aims to compatible yjs's official sync protocol. In the design of the official protocol, the situation you mentioned is possible and acceptable.

If you need horizontal scaling, redesigning a set of synchronization protocols is a better choice.

On the other hand, the apply 50m size ybinary does take some time for yjs, but in our Rust implementation, the speed will be faster.

During the unstable period of the blocksuite editor, the affine server often receives updates of tens of MB in size due to frequent modifications by the editor, and our server can still handle it with very low consumption.

darkskygit avatar Mar 12 '25 14:03 darkskygit

@darkskygit thanks for quick response.

  1. Horizontal scaling For the absence of horizontal scaling, jwst-rpc might be better to use on the client side. And the y-redis can scale horizontally, which is also agnostic to the domain logic like the workspace -> space -> block data structure abstraction, . But I prefer a Rust implementation. Are you guys interested in a Rust port please?

  2. Affine server

Just checked the source code of AFFiNE. I didn't find a direct dependency on octobase. Is the implementation not open sourced please?

videni avatar Mar 13 '25 01:03 videni

@darkskygit thanks for quick response.

  1. Horizontal scaling For the absence of horizontal scaling, might be better to use on the client side. And the y-redis can scale horizontally, which is also agnostic to the domain logic like the workspace -> space -> block data structure abstraction, . But I prefer a Rust implementation. Are you guys interested in a Rust port please?jwst-rpc
  2. Affine server

I checked the source code of AFFiNE. I didn't find a direct dependency on octobase. Is the implementation not open sourced please?

affine server has adopted a redesigned private protocol for sync, which is different from implementations like ysync/yredis, we do not have the manpower or plans to make it into an independent open-source repository now

darkskygit avatar Mar 13 '25 02:03 darkskygit

@darkskygit It is sad to hear that. I am adding real-time collaboration functions for my pdf reader and editor based on octobase. Though it is still in the prototype stage, I am very looking forward to your library. Please consider open-sourcing it when possible. I will spend lots of time tailoring it instead of reinventing the wheel.

For now, could I know the high-level design architecture of your private sync implementation please?

videni avatar Mar 13 '25 03:03 videni