I have a bunch of json objects that I need to compress, since it consumes too much disk space, approximately 20 gigs cost several million of them.
Ideally, what I would like to do is compress each one individually, and then when I need to read them, just iteratively download and unzip each one. I tried to do this by creating a text file with each line being a compressed json object via zlib, but this does not work with
decompress error due to a truncated stream ,
which, I believe, is associated with compressed lines containing newlines.
Does anyone know a good way to do this?
source share