For the last several weeks I've been working on a thorough overhaul of the 
syncer, and I'm now close to merging those changes into master. I'm posting 
here now because this is a good opportunity for developers to test projects 
that may be affected by these changes (eg TiddlyServer, Bob etc.).

The syncer is a core component responsible for two slightly different jobs:

* In the browser, the syncer is used to determine which tiddlers need to be 
loaded and saved across the network to the server
* On the server, the syncer is used to determine which tiddlers need to be  
saved to the file system

To allow the same component to be used in these two contexts we abstract the 
loading and saving to a "syncadaptor", with the "tiddlyweb" adaptor in the 
browser that uses HTTP to talk to the server and the "filesystem" adaptor on 
the server that uses the Node.js file APIs to write to the filing system.

The primary problem that I've been addressing is that up until now the internal 
state of the syncer would become corrupt after encountering network 
connectivity issues. In some situations this has led to users losing data. A 
fairly deep rewrite was necessary which means that a number of other issues 
have been addressed at the same time.

The complete list of changes is:
Improved resilience to connection errors. Errors encountered by the browser are 
automatically retried, and when they succeed the associated error messages are 
automatically removed
Changes to system tiddlers are now synchronised from the server to the browser
Deletions of tiddlers on the server are now synchronised to the browser
New animated "cloud” page control button with a dropdown menu showing status 
and additional actions:
"Refresh from server" to force an immediate check for changes from the server
"Logout"
"Save snapshot for offline use" to save a copy of the wiki without the 
client-server components
"Copy syncer logs to clipboard" to make it easier to ask end users for 
debugging information 
Added "filter" and "exclude" parameters to the [[GET 
/recipes/default/tiddlers.json|WebServer API: Get All Tiddlers]] endpoint to 
allow the returned tiddlers and fields to be filtered
Enhanced LazyLoading to include skinny versions of tiddlers in the HTML file, 
and to avoid unnecessary loads from the server
The official plugin library is now disabled when the tiddlyweb adaptor is active
Internal file system details are no longer exposed to browsers when a file 
request fails (see https://github.com/Jermolene/TiddlyWiki5/issues/3724)
All these changes are intended to be backwards compatible, and so I’d be 
grateful for any feedback before this is merged.

The pull request includes a lot of commentary about the changes:

https://github.com/Jermolene/TiddlyWiki5/pull/4373 
<https://github.com/Jermolene/TiddlyWiki5/pull/4373>

Feedback and questions welcome,

Best wishes

Jeremy








-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywikidev/8ED863CF-DC68-4D70-8826-F7ACFA186891%40gmail.com.

Reply via email to