Re: Update mechanism for standalone app/ Delta Updates
"Bastian Eicher" <[email protected]> Thu, 23 Feb 2017 18:45:05 +0100
| Newsgroups | gmane.comp.file-systems.zero-install.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi Jan, in this case the environment variable MYAPP_VIDEOS would be set to a list of multiple directories separated by : on Linux and by ; on Windows, similar to the PATH variable. The <overlay> binding was intended to support applications that do not use environment variables and expect their dependencies to be located in fixed locations. Zero Install would use a combination of chroot und a union file system to make that specific application “see” its dependency in the specified location in the filesystem without actually placing it there. However, this was never implemented, since it is rather complex and especially difficult to support on Windows. Regards Bastian From: Jan Viehweger [mailto:[email protected]] Sent: Mittwoch, 22. Februar 2017 23:23 To: [email protected] Subject: Re: [Zero-install-devel] Update mechanism for standalone app/ Delta Updates Hi Bastian, if i would use environment variable as you suggested what would happen if each implementation requires it previous version and maps it to the same env e.g., in this case "MYAPP_VIDEOS"? Could we merge / overlay the filestructure by this? I studied the xsd of ZI. I stumbled over a promising child tag <overlay src="" mount-point="" /> which i can't find in the feed specification. What's the use of it? Best regards, Jan Am 22.02.17 um 09:35 schrieb Bastian Eicher: Hi Jan, you are right, applications built on cross-platform environments like Webkit or Java are great candidates for Zero Install. Perhaps you can help spread the word. :) The easiest way to get smaller updates with Zero Install right now is to split your applications into multiple smaller components that can be updated independently. However, this would require your application to find the different “parts” of itself using environment variables. For example your main feed might reference a MyApp-Videos.xml feed like this: <requires interface=".../MyApp-Videos.xml"> <environment name="MYAPP_VIDEOS" insert="."/> </requires> Your app would then need to look in $MYAPP_VIDEOS instead of ./app/media/videos. I have no experience with Node Webkit so I do not know whether this would be easy to accomplish. Zero Install also has the concept of “recipes” that allow implementations to combine multiple archives or other steps like renames or removals. For example: <implementation version="1" id="sha256=abc"> <archive href=".../myapp-v1.zip"/> </implementation> <implementation version="2" id="sha256=xyz"> <recipe> <archive href=".../myapp-v1.zip"/> <archive href=".../myapp-v2-delta.zip"/> </recipe> </implementation> However, this would only save you from having to upload large updates. When downloading v2 Zero Install would still need to re-download v1 as well because it does not know that the existing sha256=abc implementation corresponds to the myapp-v1.zip archive recipe step. @Thomas: Perhaps we could introduce a new recipe step to handle this, for example: <recipe> <implementation id="sha256=abc"/> <archive href=".../myapp-v2-delta.zip"/> </recipe> What do you think? Regards Bastian From: Jan Viehweger [mailto:[email protected]] Sent: Montag, 20. Februar 2017 11:52 To: The Zero Install system <mailto:[email protected]> <[email protected]> Subject: [Zero-install-devel] Update mechanism for standalone app/ Delta Updates Hello list, i'm developing a cross plattform standalone app which need's an (auto/self-) update mechanism. The app is written in HTML5 & node.js and runs on Node Webkit ( <http://nwjs.io> http://nwjs.io). The problem is: Node Webkit does not provide an update feature. So i met zero install ;) . The concept behind blow my mind away and i'm wondering why it's still quite unknown (in my scope)? I'm evaluating if ZI can solve my update problem 100%. So let me explain in detail. One major requirement of the update routine is, that updates shout be as small as possible. For that purpose other tools use so called delta updates. I've already read delta updates are a upcomming feature for ZI so i asked myself if i could use a workaround: The app itself consists of a small amount of javascript but a large (and growing) number of mediafiles (images and videos). Updates will most of the time consist of changed or new mediafiles. so creating patches (delta updtes) for images or videos (where almost every pixel changes) make no sense at all. So my idea is the following pragmatic idea: * The deployed app will be versioned in a LFS ( <https://git-lfs.github.com/> https://git-lfs.github.com/) enabled GIT repo. * Each change to the repo will be flaged as a new Version. * The Diff between the last version and the current will be exported as a zip containing only the modified and new files * Transfered to ZI the idea is, that each version represents an seperate feed/interface which depends on the previous versions which by itself is an feed/interface too * By this a tree of dependencies from one to the higher version will be resoved. The big question now is, how to merge the files (each extracted archive) together in one place and override older files with newer ones? For making it more descriptive, the following filestructure makes the whole standalone app * nwjs (DIR) * nwjs.exe * ... * app (DIR) * js (DIR) * main.js * ... * templates * view1.html * view2.html * media (DIR) * videos (DIR) * movie1.mp4 * movie2.mp4 * ... * images * image1.jpg * image2.jpg * ... The "nwjs" folder represents the Node Webkit runtime which itself won't be touched. Normaly you just download it. The "app" folder contains the app to be run in Node Webkit. The app will be started by calling the nwjs.exe withe the "app" directory as the argument. The app interface/feed will be run by the Node Webkit interface. -------- Any suggestions are welcome Best regards Jan ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ Zero-install-devel mailing list [email protected] <mailto:[email protected]> https://lists.sourceforge.net/lists/listinfo/zero-install-devel ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ Zero-install-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/zero-install-devel