Section 10.1. Configure ColdFusion Server Settings for Java

   

10.1 Configure ColdFusion Server Settings for Java

In order to begin working with Java in any of the ways available, we first need to configure the ColdFusion server. To do so, open the ColdFusion MX Administrator, and click Java and JVM. The Settings window is shown in Figure 10.1. There are a few settings here that require attention.

  • Java Virtual Machine Path. This setting allows you to specify the location of the Java Virtual Machine you wish to use. Because Cold-Fusion MX is Java-based, this box will be pre- populated with <COLDFUSION_HOME>/runtime/jre . ColdFusion used to install JDK 1.3 into its directory structure.

  • Initial Memory Size (MB). This determines the amount of memory the JVM should use.

  • Maximum Memory Size (MB). This defaults to the amount of RAM on the system.

  • Class Path . Here you indicate the directories and JAR files that contain the Java classes ColdFusion will use.

  • JVM Arguments. Here you specify any additional arguments to send to the JVM. This might include, for instance, a directive to enable assertions.

Figure 10.1. Java and JVM settings in the ColdFusion MX Administrator.

graphics/10fig01.jpg

Note

Previous versions of ColdFusion had a setting allowing you to indicate whether to load the JVM automatically when ColdFusion was started. This setting is obsolete; because ColdFusion is Java-based, it must always start the JVM.


Note

It is okay to have multiple versions of the JVM installed concurrently on the same machine.


In the next section, we will write a simple Java class and invoke it from within a ColdFusion template.


   
Top


Java for ColdFusion Developers
Java for ColdFusion Developers
ISBN: 0130461806
EAN: 2147483647
Year: 2005
Pages: 206
Authors: Eben Hewitt

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net