Skip to content

Latest commit

 

History

History
49 lines (35 loc) · 1.96 KB

README.md

File metadata and controls

49 lines (35 loc) · 1.96 KB

scalable-ot

A scalable concurrent collaboration framework based on Operational Transformation (OT).

Inspired by sharedb.

Examples

Text editor

textarea

Spreadsheet

sheet

Architecture

arch

  1. Clients send operations through API.
  2. Operations are pushed into MQ, partitioned by document id.
  3. OT server receives operations of same document sequentially and performs conflict solving.
  4. Broadcast server sends conflict-free operations to clients.
  5. Conflict-free operations are pushed into another MQ(or db stream), trigger a consumer which apply them on document snapshot sequentially.

Project Structures

scalable-ot
├── front       // Client side code, including examples(textarea, spreadsheet)
├── ot-server   // Server which consume client operations and produce conflict-free operations
└── proto       // Protobuf definitions
scalable-ot-java-backend
├── scalable-ot-api         // Front facing api
├── scalable-ot-broadcast   // Web socket server which connect to clients
├── scalable-ot-consumer    // Service which consume and apply conflict-free operations
├── scalable-ot-core        // DTO, DAO, etc.
└── scalable-ot-kafka       // Kafka related configurations

Features

  • Horizontal Scalable Some services are implemented as Kafka consumer and are scalable in nature. Some are backed by RPC framework like Dubbo and have been customized to be scalable and load balanced based on specific rules.
  • Extensible Can be extended to support concurrent editing on other type of document by adding OT libraries.