It seems like something that *could* work with a single file as opposed to a folder. It would require implementing the same kind of btsync concept in Javascript of course, a non-trivial obstacle I'm going to just glide on by thank you very much.
Given that that can be done, I see two obvious problems, both involving versioning. One would be that in order guarantee updates at least one other copy would have to be open at any given moment - which one should be unimportant, as long as there is a 'chain of provenance' at any given moment - when a new tiddly wiki is opened it would update. The other would involve two or more people simultaneously editing a single tiddler; Some variation of 'diff'' logic would seem suitable.
Regarding to the context of your seafile presentation:
1. Looks like you worked with tiddlywiki on node.js in seafile, since I saw multiple separated files for each tiddler - did you (I did not yet, only have read about)?
2. That the inconsistent (conflict) file is brought up by seafile is nice, but do you get noticed about that?
2.1 Say you have 300 tiddlers aka 300 files - you'll not be able to discover on your own when a new conflict file will appear among them. So do you get a notice of the conflict?
3. Another question regarding node.js and multiple files - is that working on ios and android as well?
4. Is multiuser editing considered at all in the design of tw5?
Because I only saw that you can enter the username in the properties of tw5, but whoever edits the wiki afterwards does it with the pre-entered user name if she's paying no attention - that's not relyable.
I think with all these shared / collaboration concepts one thing is key:separating "the wiki(s)" from "the store(s)"
For collaboration around TiddlyWiki, the single-file paradigm is essentially untenable,
not just for the simple reason that to currently push 1 byte of "changed tiddler"you my need to push +2mb of "changed wiki"... unless you're using a pretty vulnerable node server.
2. That the inconsistent (conflict) file is brought up by seafile is nice, but do you get noticed about that?
You don't. If you reload the page, you'll see, that there are conflicting files. ... But TW doesn't have an easy mechanism to see the differences. ... So some manual work needs to be done, resolving the conflicts.
2.1 Say you have 300 tiddlers aka 300 files - you'll not be able to discover on your own when a new conflict file will appear among them. So do you get a notice of the conflict?
Page reload.
3. Another question regarding node.js and multiple files - is that working on ios and android as well?
I don't think, that nodejs works on IOS. I'm not sure about android. ... IMO If you need mobile access, you can use TW apps. There are some of them, but I don't know the links. ... There is no server side atm, to sync and resolve conflicts.
If somebody would ask me for a blueprint of file level syncing of TW5 in a efficient but also simple way I would suggest the following:
- keep things simple with the single file approach - over disadvantages it has many advantages
- a session would mean here that you start with a synced wiki (copies) and do handshakes by determining the name (convention) of the syncStatus file considering the current cloud conditions
- after the sync the syncfile of A has to be deleted by B and A is not allowed to write a new syncfile while the old syncfile exists
Am Dienstag, 27. Januar 2015 11:09:29 UTC+1 schrieb PMario:Page reload.
Sorry, I was speaking here about the seafile service and not about tw. But I think you mean a page reload inside seafile as well. That's what I mean is a problem.
1. you have to do a page reload
2. i don't think that you recognize one more file (the conflict file) among 300 other files in meaningful time without to get noticed by seafile.
Do you get noticed be seafile??
Then is mobile use not possible on side B when on side A there is the node.js version running with multiple files getting synced to A??
I am using TW apps for mobile access right now, but i am working with the single file tw at the moment - and it's quite handy.
2.1 Say you have 300 tiddlers aka 300 files - you'll not be able to discover on your own when a new conflict file will appear among them. So do you get a notice of the conflict?
Page reload.
If we speak about distribution on file level (in the cloud) the question is if it's neccessary to do that separation of data & logic on file level as well. One would think so.
But I like the 1 file approach of tw5 very much and would not like to give it up if it's not really neccessary - it makes things very handy at all.
If somebody would ask me for a blueprint of file level syncing of TW5 in a efficient but also simple way I would suggest the following:
- keep things simple with the single file approach - over disadvantages it has many advantages
- on sync side A:
-- use the TW5 autosave capabilities to do not a save but an export of a file (call it syncStatusA) that has the following contents
--- the logic to say what has changed (tiddler updated)
--- the data that changed (tiddler data)
-- the exported file will be automatically synced (if thats possible) by the cloud service client you are using (it's possible in mine)
- on sync side B:
-- use the TW5 autosave logic to do an import (read) instead of an export (if that's possible???)
-- look for a exported file that has also been synced in the current file space (the syncStatusA file) and import it
-- maybe a file naming convention for the syncStatus file is neccessary & sufficient here, but a property inside tiddlywiki describing the exact name of the import file for the current session would do it
- if you don't want to think about the implications by working with both wikis on sides A & B on one and the same syncStatus file, then you have to choose a different name for the import and the export file of one wiki - or respectively, choose a different name of the syncStatus import/export file on both sides A & B - then you have a handshake, don't you?!
- naming the import & export file different would be meaningful to make the sync robust for the unknown conditions of the cloud service (sometimes there's automatic file versioning, etc.)
- so finally, the names of the files could be syncStatusA and syncStatusB and they would be synced by the cloud service and carry the information and data what has changed and will be imported automatically
- and with minimal manual interaction of an handshake for a session you could have a synced tw5
- a session would mean here that you start with a synced wiki (copies) and do handshakes by determining the name (convention) of the syncStatus file considering the current cloud conditions
- after the sync the syncfile of A has to be deleted by B and A is not allowed to write a new syncfile while the old syncfile exists
-- that would work for a little number (10?) of team members, at least for 2, wouldn't it?
- if you are more than 2 - say 10 - and you need for technical tw reasons not the naming convention but the exact name of the syncStatus file, then you would need the possibility to tell your tw not only one import/export naming convention of the syncfile, but 10
- in this case after updating a tiddler on side A nine (9) syncfiles will be created for the team members
- so sync should be possible this way for small teams and I think you could put that functionality into a plugin
- this would keep things quite handy for a 3 person team and would be a large benefit in workflow
I'm sure there are quite some users, that would be happy with this mechanism, because it has no dependencies. It's extremely simple. An if you only did eg: 10 small changes in the text. Resolving will be fast too.
If somebody would ask me for a blueprint of file level syncing of TW5 in a efficient but also simple way I would suggest the following:
- keep things simple with the single file approach - over disadvantages it has many advantages
- on sync side A:
-- use the TW5 autosave capabilities to do not a save but an export of a file (call it syncStatusA) that has the following contents
--- the logic to say what has changed (tiddler updated)
--- the data that changed (tiddler data)
-- the exported file will be automatically synced (if thats possible) by the cloud service client you are using (it's possible in mine)
- on sync side B:
-- use the TW5 autosave logic to do an import (read) instead of an export (if that's possible???)
-- look for a exported file that has also been synced in the current file space (the syncStatusA file) and import it
-- maybe a file naming convention for the syncStatus file is neccessary & sufficient here, but a property inside tiddlywiki describing the exact name of the import file for the current session would do it
When I started tiddlydrive that was my goal. Currently the project is frozen, but you can check it out at http://danielo515.github.io/TiddlyDrive4Community Basically is a single file HTML that syncs from and to google drive.
- a session would mean here that you start with a synced wiki (copies) and do handshakes by determining the name (convention) of the syncStatus file considering the current cloud conditions
If you use your file based handshake, you need to sync the handshake = "lock file". ... But this is a "chicken / egg" problem.
To trigger the "3rd party syncing action" you need to delete the lock file on side A. -> syncing is triggered, but doesn't work -> So you are out of sync.
A thinks I'm ok
B thinks A is still locked ... The problem here is the 3rd party transport. Because you can't trust it. So the locking mechanism needs to be more sophisticated. ...- after the sync the syncfile of A has to be deleted by B and A is not allowed to write a new syncfile while the old syncfile exists
This is a typical condition for a "dead lock", where both sides are locked, because the "delete" action didn't work, for some unknown reason.
- after the sync the syncfile of A has to be deleted by B and A is not allowed to write a new syncfile while the old syncfile exists
This is a typical condition for a "dead lock", where both sides are locked, because the "delete" action didn't work, for some unknown reason.
-m
The agreement just consists of the names of the syncfiles. The important point I may have forgotten to mention explicitely is that the information about the syncfile of A is told to B in a meta way.
Which means that the name of the syncfile of A is told B per comment / chat / social functionality of the sync carrier (the cloud service).
In a case where you have a single wiki in a directory in sync over a cloud service you have to exchange this meta information only once!
In theory, the meta thing might be not elegant.
In reality it would be highly practical, because you only have to exchange the meta information when your team changes or the cloud service does - that would be really convenient.
I don't see the deadlock with the information provided regarding the meta information exchange.
If there is a syncfile from tw A for tw B, then tw B should delete it after:
- the syncfile was recognized (tw B could check every 10 seconds) and
-- tw B updated itself according to the syncfile from A
-- tw B does nothing, because it's already in sync