Prefer lz4 compression, allow specifying compression type

This is related to #1