Maybe someone out there has done this successfully, or knows the pitfalls. I would like to use a
JSP response in the following manner:
byte[] pdfBytes = report.pdfBytes();
// send the pdf bytes to the response
response.setContentType("application/pdf");
response.setContentLength(pdfBytes.length);
ServletOutputStream out = response.getOutputStream();
out.write(pdfBytes);
out.close();
The intent here is to use a JSP in place of a
Servlet to write pdf reports. I haven't tried it yet, but have a feeling there is something wrong with my approach. Thanks ahead of time !