Note Synchronization: Development


  • 321037 - synchronize notes across multiple machines

    • Find/put patches here




Foreign XML

  • [ ] Generating link:internal tags on appropriate text (currently only happens after first edit)
  • [ ] Verifying existing link tags (ie link:internal tags that don't make sense in our Tomboy instance should become link:broken tags or should disappear internally)
  • [ ] Define metadata sync policy (pins, open-on-startup, etc)
  • [ ] Change cursor position when creating new note from foreign XML? Seems especially useful during --open-note
  • [ ] Check note XML version?
  • [ ] Currently syncing created/modified date/time. Although these values are listed with GMT offset, still have to consider situation where a user's system clock is just plain wrong.

Sync Algorithm

  • [ ] Enumerate all possible combinations of note status locally and remotely, ensure these scenarios are accounted for
  • [ ] When in doubt, trust server, right?
  • [ ] Weird situations:
    • Many weird situations can be avoided by performing an update in three distinct steps: deletes, then updates, then adds.
    • Notes A and B swap titles for Client 1. Client 1 syncs. Client 2 initiates sync. How does Client 2 decide that it's OK to have two notes with the same name, even temporarily? Is it OK (think of failures)?
  • [X] If a conflict is detected but the note contents are identical, don't bother the user, Just Do It
  • [ ] (If there's time) Allow addins to provide an entirely different sync algorithm. For example, a Conduit addin could use our "Synchronize Notes" menu item to initiate a conduit sync, and use our main sync progress dialog to report its status. But it would not necessarily need to update any manifest.xml, etc. One approach to allowing this would be to encapsulate the sync algorithm in a strategy pattern, and allow addins to provide different strategies. The main strategy would be to use the TomboySyncClient and some SyncServiceAddin, but Conduit could provide its own strategy that simply calls Conduit over DBUS and makes a few calls to update our sync progress dialog. I believe this could be achieved by tweaking the SyncServiceAddin interface (add a method to perform the sync or provide an object encapsulating the correct sync strategy/behavior, remove a couple of methods specific to the existing sync strategy). Sorry for the brain dump...I'll clean this up later.


  • [X] Best way to find executables
  • [ ] Best way to check module list (same concerns as enabling FUSE)
  • [ ] Best way to enable FUSE (need to be really careful here, any way to check exact distro+version?)
  • [~] Doesn't blow up if there is no fuse or platform is weird, can't find all stuff, etc (with helpful messages to user, too)
  • [X] Unmount FUSE when Tomboy exits, regardless of timer state (or unmount whenever not needed?). Don't freak out if it's already mounted. Output of mount isn't particularly trustworthy here!

  • [ ] Would be nice to be able to guarantee unmount no matter how Tomboy exits. Currently if Tomboy crashes it doesn't unmount.
  • [ ] Unless we can find a way to do something with a user's ssh password, find a good way to explain to user that they'll need an ssh key all set up, for advanced users, etc.


  • [ ] Bullet-proof failure detection
  • [ ] Better cleanups after failures
  • [ ] Better data maintainence (on server: duplicate notes, empty rev folders, etc)
  • [ ] Perform sync server "consistency check" every 30 revs or so to clean out obsolete/duplicate notes/manifests, etc. A sync operation isn't a failure if the only thing it fails to do is clean up that stuff. Don't want to do it every time because it involves iterating through the contents of every rev dir.


  • [ ] Any time user is prompted for action, have an "Always do it like this" option? Would have to mirror those settings in the prefs dialog...
  • [ ] Better, prettier, more informative dialogs
    • [ ] Give user some hints if we can't programatically enable FUSE
  • [~] Notes listed in sync dialog should openable via double-click, draggable, etc.
  • [ ] Disable menu items when no sync configured? Or launch prefs?
  • [ ] Build-time option?
  • [X] Wrap translatable strings in Catalog.GetString

  • [ ] Icon for "sync now" menu items

Apps/Tomboy/Synchronization/Development (last edited 2013-08-09 00:14:59 by WilliamJonMcCann)