docs: public void flushResponse() throws IOException {
          try {
              // Finish GZIP encodig
              if (gzipOut != null) {
                  gzipOut.finish();
              }
  
              flushBuffer();
          }
          finally {
              // Close stream
              if (writer != null) {
                  writer.close();
              }
              else {
                  if (out != null) {
                      out.close();
                  }
              }
          }
      }