Compressed File (*.z8) Specification
The *.z8 files use industry-standard stream compression/decompression library 'ZLIB'. Please refer to the original vendor's web site
for specification of the compression/decompression interfaces in greater detail, as well as for latest updates and versions.
The ZLIB interface allows you to quickly compress and decompress streaming data and achieve outstanding compression ratios.
All this provides significant benefits when dealing with large amounts of data associated with order flow.
On multi-core systems, performance can be almost doubled by unpacking the stream in one thread,
and performing actual processing in another thread.
The *.z8 file format is very simple.
||The size of the unpacked stream. It can be useful when reading the decompressed stream via a decompression library
that does not provide an End-Of-File flag for input.
||The compressed stream itself.
You can also follow these algorithms to read the data from *.z8 files:
- Open the source *.z8 file
- Skip the first 8 bytes
- Read a portion of compressed data into the source buffer
- Uncompress data from the source buffer into the destination buffer using ZLIB 'inflate' interface
- Repeat step 3 until the end of the source file
- Flush the destination buffer and close the source file
- Open the source *.z8 file as a File stream
- Read the destination file size into a 64-bit signed integer N
- Create a Decompression stream and assign the File stream as its input
- Read N bytes from Decompression stream
- Close Decompression and File streams
You can also use the tools for handling the *.z8 files