Realtime collaborative page editing
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mahara |
Confirmed
|
Wishlist
|
Unassigned |
Bug Description
People would like to be able to collaboratively edit Mahara pages in realtime. I was discussing this with Robert and it actually might not be that hard to do, at least for group pages (which are already collaboratively editable). You'd just have to take things at a block-by-block basis.
1. When you're editing a group page, we use Ajax to periodically poll the server to determine if someone else is also editing the page.
2. If someone else is editing the page, we show them listed at the top of the page as a collaborative editor. (Maybe some kind of chat system to go along side this?) You also poll more frequently.
3. When there are updates to the page, made by someone else, we load them onto the page immediately.
4. If someone else is editing a block, we "lock" that block. (In the long run we could have a flag for some types of blocks to be multi-user collaborative.)
The tricky part here is that you need to be able to track and update (or lock) all the ways that a page can be updated:
- reloading block contents
- adding blocks
- deleting blocks
- moving blocks
And also page metadata...
- changing page layout
- changing page title/descripti
It would probably be easiest to lock the page metadata while someone is editing the page. Also, what if someone opens a block for editing, and then they close their window, or their browser crashes? We need the block to automatically unlock. Perhaps a "keepalive" ping once per minute.
Changed in mahara: | |
milestone: | 15.10.0 → 16.04.0 |
Changed in mahara: | |
milestone: | 16.04.0 → 16.10.0 |
Changed in mahara: | |
milestone: | 16.10.0 → 16.10.1 |
Changed in mahara: | |
milestone: | 16.10.1 → 17.04.0 |
Changed in mahara: | |
milestone: | 17.04.0 → none |
Rather than polling, look into something like http:// en.wikipedia. org/wiki/ Comet_% 28programming% 29
There are some great libraries to abstract all the logic and fallbacks away :-)