View Full Version : cfdocument timeout - fixing timeout problems with cfdocument

June 23rd, 2011, 01:02 PM
If you have received the following error:

The Content Of This Document Process Takes More Than 60000 Milliseconds To Process

There are a few performance tips include:

1. If your running a query to gather data for generating the PDF. Verify your query is running quickly, this can be done by:

Using a SQL tool to analyze the query, speed.
Using cflog to log before and after the query to analyze how quickly the cfquery tag executes.

2. Eliminate external http calls to include in the document.

Example 1:

<link rel="stylesheet" type="text/css" href="../css/styles.css">

Change To

<link rel="stylesheet" type="text/css" src="#ExpandPath('../css/')#styles.css">

Example 2:

<img src="../../images/client/Logo.jpg" />

Change To

<img src="#ExpandPath('../../images/client/')#Logo.jpg" />

3. Tell the JVM server that you're not expecting it to display the information locally. This can dramatically increase performance. Set the following paramater in the JVM config file:
Read more about this argument here. (http://java.sun.com/developer/technicalArticles/J2SE/Desktop/headless/)

NOTE For customers: We have the JVM argument in tip #3 set as a default setting.

NOTE about FireFox: A bug we found with the Mac FireFox Browser is that the file attempts to be downloaded with the .CFM format instead of being displayed in the browser. One fix would be to write the file to disk.