title: PDF Compression Techniques
body: <p>I am trying to compress PDF document in Java. The original file size is 1.5-2 MB and we need to bring it down to less than 1 MB.  I tried using iText compression on it, however the results are not that effective and file size is still greater than 1 MB. </p>
  
  <pre><code>byte[] mergedFileContent = byteArrayOS.toByteArray();
  reader = new PdfReader(mergedFileContent);
  PdfStamper stamper = new PdfStamper(reader, byteArrOScomp);
  stamper.setFullCompression();
  stamper.close();
  reader.close();
  </code></pre>
  
  <p>Has anyone worked on something similar? Any inputs would be appreciated.</p>