Accessibility

TechNote

ColdFusion MX 6.1: Error parsing large XML documents

Issue


Parsing large XML documents in Macromedia ColdFusion MX 6.1 may fail with the following error:

 org.xml.sax.SAXParseException: Parser has reached the entity  expansion limit "64,000" set by the Application 

ColdFusion MX 6.1 ships with Sun Microsystem's JVM version 1.4.2-b28. In this version of the JVM, there is a new system property to limit entity expansion. TheentityExpansionLimit system property lets existing applications constrain the total number of entity expansions without recompiling the code. The parser throws a fatal error once it has reached the entity expansion limit.

Solution


Using the steps below, change theentityExpansionLimit size to a higher value.

Server Configuration
  1. Open the ColdFusion MX Administrator and navigate to the Java and JVM Settings page.
  2. In the JVM Arguments field, add the following option with the desired limit:

    -DentityExpansionLimit=100000

    Note: When specifying multiple arguments, options must be separated by spaces.
  3. Click Submit Changes to save your changes.
  4. Restart the ColdFusion Application Server service for the change to take effect.
  5. If the error still occurs, increase the value specified in the option.
J2EE with JRun Configuration
  1. Locate the jvm.config file in the jrun_root\bin directory.
  2. Make a back-up copy of the file.
  3. Open the original jvm.config file for editing.
  4. Add the following option, with the desired limit, to the list of Java arguments:

    -DentityExpansionLimit=100000

    For example:
     # Arguments to VM java.args=-server -Xmx512M -DentityExpansionLimit=100000 
  5. Save the changes to the file.
  6. Restart the deployed instance(s) of ColdFusion for the change to take effect.
  7. If the error still occurs, increase the value specified in the option.


AlertThis content requires Flash

To view this content, JavaScript must be enabled, and you need the latest version of the Adobe Flash Player.

Download the free Flash Player now!

Get Adobe Flash Player

Creative Commons License

Search Support


Document Details

ID:tn_19125
Browser:Chrome
Internet Explorer
Netscape
Opera
Safari
Firefox

Products Affected: