Skip to main content
Known Participant
October 28, 2010
Question

CFDOCUMENT PDF generation peformance on Linux running CF server 8 or 9 is horrible

  • October 28, 2010
  • 2 replies
  • 837 views

Can anyone help me understand how I can get the <cfdocument> tag to generate PDFs in reasonable time (and without throwing timeout errors) when running on CF 8 on Linux? Running on CF 9 doesn't make a difference, either. I can run the same code that generates a PDF on a Win 7 system and it completes the 1-2 page PDF in seconds.  Do the same thing in CF8/9 on Linux and it takes so long (minutes) and then throws a timeout error. When we tried using Railo instead of CF8/9 it ran fine as well.

    This topic has been closed for replies.

    2 replies

    Tea manAuthor
    Known Participant
    October 28, 2010

    See above answer.

    Tea manAuthor
    Known Participant
    October 28, 2010

    Our apps guy figured out the problem after googling the error log message. To put this in context, the deployed app is running in a Tomcat container on Linux.

    The root cause is Java's AWT thinking there should be an Xserver available to talk to.  Somehow in the code interactions during the PDF generation,  calls are made to an Xserver that doesn't exist, with an absurdly long  timeout.  Adding the line "-Djava.awt.headless=true" to the catalina.sh  script has solved the issue.

    Hope this helps others!

    Tea man