Changed the default block size of SnappyOutputStream to 8kb from 4MB

This commit is contained in:
Taro L. Saito 2011-06-10 09:52:51 +09:00
parent 11e8be1561
commit e321bee6c1
1 changed files with 2 additions and 2 deletions

View File

@ -31,7 +31,7 @@ import java.io.OutputStream;
* This class implements a stream filter for writing compressed data using * This class implements a stream filter for writing compressed data using
* Snappy. * Snappy.
* *
* The input data is blocked into 4 MB size (in default), and each block is * The input data is blocked into 8kb size (in default), and each block is
* compressed and then passed to the given {@link OutputStream}. * compressed and then passed to the given {@link OutputStream}.
* *
* The output data format is a sequence of (compressed chunk size, compressed * The output data format is a sequence of (compressed chunk size, compressed
@ -42,7 +42,7 @@ import java.io.OutputStream;
*/ */
public class SnappyOutputStream extends OutputStream public class SnappyOutputStream extends OutputStream
{ {
static final int DEFAULT_BLOCK_SIZE = 4 * 1024 * 1024; // Use 4 MB for the default block size static final int DEFAULT_BLOCK_SIZE = 8 * 1024; // Use 8kb for the default block size
protected final OutputStream out; protected final OutputStream out;
private final int blockSize; private final int blockSize;