• Post Reply Bookmark Topic Watch Topic
  • New Topic

Dynamic PDF Generation using Apache FOP

 
lekurwale amol
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Hope this is the right place to post my question.
I am using Apache FOP to display some report to the user in PDF format.
For testing purpose, I am using a hardcoded data XML and a XSL to generate the PDF
It is working fine.
Now, I need to deploy it on the server. The contents of the tags of XML will be generated through some Java classes (inshort dynamic values). Now FOP needs the xml file to be stored somewhere, from where it reads. I can 'write' the XML to the server which FOP can use.
BUT it has a very important issue of security, as the xml file written on server contains sensitive data. Also, once written, the file needs to be completely deleted, as they will continue accumulating as the user access it.
My question : Is there any way in which, I can write a template XML on the server, of whose tag values are populated at runtime and passed onto fop, and the PDF gets generated. That ways, the 'data XML' will not have to be written on the server. So the security and storage concern will be addressed.

Regards,
Amol
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm pretty sure that FOP can work with streams, in addition to working with files. So the XML data most likely never needs to be written to disk.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!