File Compression Support in JANOS September 30, 2017
As you know we have been supporting ZIP and JAR files (they are the same as far as JANOS is concerned) for a while. JAR files being predominantly for application programs and Java support. More recent OS versions allow the WebServer to serve files directly out of a ZIP library. The DCP is an example where you need only add the www.zip
file to the /flash folder to install the set of files that are the DCP. There is no need to expand the library.
To do this JANOS is able to understand the ZIP/JAR file structure and extract data stored within it with either the STORE or DEFLATE methods. Presently JANOS cannot handle the LZW compression or many other ZIP options such as encryption.
I had once developed a program called “Curator” which was a backup utility that worked much like SVN and stored all of its data using LZW compression. We were always amazed at the compression ratios. I had even worried at times that there might have been a problem in figuring that ratio because sometimes it seemed way off. But the program worked and accurately recovered data.
So I do have code that I have written (although in C++ in that case) that can be used in JANOS to handle LZW. We just haven’t encountered it. Apparently DEFLATE is the compression method of choice.
So I expect that we will encounter externally zipped libraries that JANOS will not be able to process. In those cases depending on the reasons for the incompatibility I am prepared to implement the fix.
But the question now is whether or not there would be any use in the JAR command being able to compress files and create libraries? I realize it has been suggested and even entered in our Redmine system. Would this be something worth doing?