title: Embed raw bytes as a PDF in JSP
body: <p>I have a bean with the raw bytes of a PDF that is generated at the user's request. I want to display this PDF to the user without really persisting the PDF file on my server. </p>
  
  <p>In my jsp I have tried tags like</p>
  
  <pre><code>&lt;object data="#{bean.pdfBytes}" type="application/pdf" &gt;&lt;/object&gt;
  &lt;object type="application/pdf" width="600" height="400"&gt;
      &lt;h:outputFormat value="#{bean.pdfBytes}" escape="false"/&gt;
  &lt;/object&gt;
  </code></pre>
  
  <p>but this fails terribly. Any help would be appreciated. Thanks in advance.</p>