{"id":279,"date":"2014-09-08T17:17:32","date_gmt":"2014-09-08T22:17:32","guid":{"rendered":"http:\/\/codezen.org\/canto-ng\/?p=279"},"modified":"2014-09-08T17:17:32","modified_gmt":"2014-09-08T22:17:32","slug":"sept-8th-2014","status":"publish","type":"post","link":"https:\/\/codezen.org\/canto-ng\/2014\/09\/08\/sept-8th-2014\/","title":{"rendered":"Sept. 8th, 2014"},"content":{"rendered":"<p>A few interesting things done in the daemon.<\/p>\n<p>First, the daemon should be <strong>a lot more memory friendly<\/strong>. With proper threading a lot of cleanup work can go on in the background, so the &#8211;nowb flag is now obsolete and the database is constantly synchronized and trimmed when work is completed. My practical experiments (8-10 hour long canto-daemon instances) showed about a 50% decrease from older versions with no plugins running.<\/p>\n<p>Second, <strong>file sync plugins<\/strong> were added to allow you to synchronize your database between multiple daemon instances. WAN and LAN facing canto-daemons have been operational since day one (with SSH port forwarding for any semblance of security), but now you can sync to any place accessible via rsync &#8211; which includes remote SSH servers and also local filesystems so you could pair it with sshfs\/NFS\/Dropbox you&#8217;ve setup previously. The plugins still require more testing, but so far they&#8217;ve been pretty well behaved here. They do need additions for <code>canto-remote sync<\/code> to work, but for now it syncs on start, stop, and periodically in between.<\/p>\n<p>To try it out, copy or link <code>canto-next\/plugins\/sync*<\/code> to <code>~\/.canto-ng\/plugins\/<\/code> and then tweak <code>sync-rsync.py<\/code> to set a <code>SYNC_LOCATION<\/code> (read the top of the file) and restart the daemon. Do the same (or copy over) on another machine to sync between the two.<\/p>\n<p>Some plugin control switches were added, mostly for debugging, and some other minor cleanups too like closing the dangling configuration file handle.<\/p>\n<p>All in all, I&#8217;m pleased with the progress of both memory consumption and a heavy duty use of the plugin architecture.<\/p>\n<p>My next bit is to round out the <code>canto-remote<\/code> part of the file sync plugins and then I&#8217;ll be back to canto-curses to work on more polish.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A few interesting things done in the daemon. First, the daemon should be a lot more memory friendly. With proper threading a lot of cleanup work can go on in the background, so the &#8211;nowb flag is now obsolete and the database is constantly synchronized and trimmed when work is completed. My practical experiments (8-10 <a class=\"read-more\" href=\"https:\/\/codezen.org\/canto-ng\/2014\/09\/08\/sept-8th-2014\/\">[&hellip;]<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"_links":{"self":[{"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/posts\/279"}],"collection":[{"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/comments?post=279"}],"version-history":[{"count":3,"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/posts\/279\/revisions"}],"predecessor-version":[{"id":282,"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/posts\/279\/revisions\/282"}],"wp:attachment":[{"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/media?parent=279"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/categories?post=279"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/codezen.org\/canto-ng\/wp-json\/wp\/v2\/tags?post=279"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}