http://Learning-Layers-eu 1
• Real-time collaboration beyond Google Docs
• Need of a scalable, easy-to-use framework
2
Collaboration
Engine
• Solving conflicts in real-time collaboration
• Architectures
– Peer-to-peer
• Components
– Collaboration Engine
– Communication component
3
4
http://y-js.org/examples/
• Text
• Json
• XML (DOM)
But: possible to customize it for arbitrary ones!
5y-js.org/examples
• XMPP
– Uses XEP-0045 (Multi-User Chat)
– Prosody XMPP server
• WebRTC
– Uses PeerJS for messaging
• .. (you can create your own connector)
6
1.var connector = Y.XMPP().join("my-roomname");
y-js.org/examples
• Similar behavior for other data types
7
1.var y = new Y(connector); //yjs object
//add a new property
2.y.val("new_object",“a_value“);
3.y.val("number",4)
4.y.val() // => {string:“a_value“,number:4}
y-js.org/examples
• Real-time collaboration on arbitrary data types• P2P message propagation• Arbitrary communication protocols
– XMPP Connector: scalable (>1000 users)– WebRTC: fast
• Easy to use• Offline editing (unimplemented)• Undo (unimplemented)
Try Yjs yourself:
https://github.com/rwth-acis/yjs8