Server Settings section

The Server Settings section lets you manage client and memory variables, mappings, charting, and archiving. You also configure mail and Java settings in this section.

Settings page

The Settings page of the ColdFusion Administrator contains configuration options that you can set or enable to manage ColdFusion MX. These options can significantly affect server performance. The following table describes the settings:
Setting
Description
Limit simultaneous requests
Enter a number to limit simultaneous requests to ColdFusion MX. When the server reaches the limit, requests are queued and handled in the order received. Limiting the number of simultaneous requests can improve performance.
Timeout requests after [n] seconds
Enable this option to prevent unusually lengthy requests from using up server resources. Enter a limit to the time that ColdFusion MX waits before terminating a request. Requests that take longer than the timeout period are terminated.
Use UUID for cftoken
Specify whether to use a universally unique identifier (UUID), rather than a randon number, for a cftoken.
Enable Whitespace Management
Enable this option to compress runs of spaces, tabs and carriage return/line feeds. Compressing whitespace can significantly compact the output of a ColdFusion page.
Missing Template Handler
Specify a template to execute when ColdFusion MX cannot find a requested page.
Site-wide Error Handler
Specify a page to execute when ColdFusion MX encounters an error while processing a request.

Caching page

The Caching page of the Administrator contains configuration options that you can set or enable to cache templates, queries, and data sources. These options can significantly affect server performance. The following table describes the settings:
Setting
Description
Template cache size (number of templates)
Enable this option to limit the memory reserved for template caching. For best performance, set this to a value that is large enough to contain your application's commonly accessed ColdFusion pages, yet small enough to avoid excessive reloading. You can experiment with a range of values on your development server; a suitable starting point is one page per MB of JVM size.
Trusted cache
Enable this option if you want ColdFusion MX to use cached templates without checking whether they changed. For sites that are not updated frequently, using this option minimizes file system overhead.
Limit the maximum number of cached queries on the server to [n] queries
Enable this option by entering a value to limit the maximum number of cached queries that the server maintains. Cached queries allow retrieval of result sets from memory rather than through a database transaction. Because queries reside in memory, and query result set sizes differ, you must provide a limit for the number of cached queries. You enable cached queries with the cachedwithin or cachedafter attributes of the cfquery tag.

Client Variables page

Client variables let you store user information and preferences between sessions. Using information from client variables, you can customize page content for individual users.

You enable client variable default settings in ColdFusion MX on the Client Variables page of the Administrator. ColdFusion MX lets you store client variables in the following ways:

You can override settings specified in the Client Variables page using the attributes of the cfapplication tag. For more information, see Developing ColdFusion MX Applications with CFML

The following table compares these storage options:
Storage type
Advantages
Disadvantages
Data source
  • Can use existing data source
  • Portable: not tied to the host system or operating system
  • Requires database transaction to read/write variables
  • More complex to implement
Browser cookies
  • Simple implementation
  • Good performance
  • Can be set to expire automatically
  • Client-side control
  • Users can configure browsers to disallow cookies
  • ColdFusion MX limits a cookie's data to 4 KB
  • Netscape Navigator allows only 20 cookies from one host; ColdFusion MX uses three cookies to store read-only data, leaving only 17 cookies available
System registry
  • Simple implementation
  • Good performance
  • Registry can be exported easily to other systems
  • Server-side control
  • Possible restriction of the registry's maximum size limit on Windows in the Control Panel
  • Integrated with the host system: not practical for clustered servers
  • Solaris, Linux, and HP-UX registries are text files. Their registries deliver slow performance and low scalability.

Migrating client variable data

To migrate your client variable data to another data source, you should know the structure of the database tables that store this information. Client variables stored externally use two small database tables, like those shown in the following tables:
CDATA Table
Column
Data type
cfid
CHAR(64), TEXT, VARCHAR, or equivalent
app
CHAR(64), TEXT, VARCHAR, or equivalent
data
MEMO, LONGTEXT, LONG VARCHAR, or equivalent
CGLOBAL Table
Column
Data type
cfid
CHAR(64), TEXT, VARCHAR, or equivalent
data
MEMO, LONGTEXT, LONG VARCHAR, or equivalent
lvisit
TIMESTAMP, DATETIME, DATE, or equivalent

Creating client variable tables

Use the following sample ColdFusion page as a model for creating client variable database tables in your own database. However, keep in mind that not all databases support the same column data type names. For the proper data type, see your database documentation.

Tip:   The ColdFusion Administrator can create client variable tables for data sources that use bundled JDBC drivers. For more information, see the online Help.

Sample table creation page

<!---- Create the Client variable storage tables in a datasource. 
This example applies to Microsoft Access databases --->

<cfquery name="data1" datasource="#DSN#">
CREATE TABLE CDATA
(
    cfid char(20),
    app char(64),
    data memo
)
</cfquery>

<cfquery name="data2" datasource="#DSN#"> 
  CREATE UNIQUE INDEX id1 
  ON CDATA (cfid,app)
</cfquery>
   
<cfquery name="global1" datasource="#DSN#">
CREATE TABLE CGLOBAL
(
    cfid char(20),
    data memo,
  lvisit date
)
</cfquery>

<cfquery name="global2" datasource="#DSN#"> 
  CREATE INDEX id2 
  ON CGLOBAL (cfid)
</cfquery>

<cfquery name="global2" datasource="#DSN#"> 
  CREATE INDEX id3 
  ON CGLOBAL (lvisit)
</cfquery>

Memory Variables page

You use the Memory Variables page of the ColdFusion Administrator to enable application and session variables server-wide. By default, application and session variables are enabled when you install ColdFusion MX. If you disable either type of variable in the Memory Variables page, you cannot use them in a ColdFusion application.

You can specify maximum and default timeout values for session and application variables. Unless you define a timeout value in Application.cfm, application variables expire in two days. Session variables expire when user sessions end. To change these behaviors, enter new default and maximum timeout values on the Memory Variables page of the Administrator.

Note:   Timeout values that you specify for application variables override the timeout values set in Application.cfm.

You can also specify whether to use J2EE session variables. When you enable the J2EE session variables, ColdFusion creates an identifier for each session and does not use the CFToken or CFID cookie value. For more information, see Developing ColdFusion MX Applications with CFML.

Mappings page

You use the Mappings page of the ColdFusion Administrator to add, update, and delete logical aliases for paths to directories on your server. ColdFusion mappings apply only to pages processed by ColdFusion MX with the cfinclude and cfmodule tags. If you save CFML pages outside of the web_root (or whatever directory is mapped to "/"), you must add a mapping to the location of those files on your server.

Assume that the "/" mapping on your server points to C:\CFusionMX\wwwroot, but all your ColdFusion header pages reside in c:\2002\newpages\headers. In order for ColdFusion MX to find your header pages, you must add a mapping in the ColdFusion Administrator that points to c:\2002\newpages\headers (for example, add a mapping for /headers that points to c:\2002\newpages\headers). In the ColdFusion pages located in C:\CFusionMX\wwwroot, you reference these header pages using /headers in your cfinclude and cfmodule tags.

Note:   ColdFusion mappings are different from web server virtual directories. For information on creating a virtual directory to access a given directory using a URL in your web browser, please consult your web server's documentation.

Mail Server page

You use the Mail Server page of the ColdFusion Administrator to specify a mail server to send automated e-mail messages. ColdFusion MX supports the Simple Mail Transfer Protocol (SMTP) for sending e-mail messages and the Post Office Protocol (POP) for retrieving e-mail messages from your mail server. To use e-mail messaging in your ColdFusion applications, you must have access to an SMTP server and/or a POP account.

The ColdFusion implementation of SMTP mail uses a spooled architecture. This means that when a cfmail tag is processed in an application page, the messages generated might not be sent immediately. If ColdFusion is extremely busy or has a large queue, delivery could occur after some delay.

Note:   For more information about the cfmail tag, see Developing ColdFusion MX Applications with CFML.

Mail Connection Settings area

Select preferences for handling mail logs, as described in the following table:
Setting
Description
Mail Server
Lets you enter a valid mail server for sending dynamic SMTP mail messages in the text box. You can enter an Internet address, such as mail.company.com or the IP address of the mail server, such as 127.0.0.1.
Server Port
Enter the number of the port on which the mail server is running. Contact your server administrator if you are unsure of the appropriate port number.
Connection Timeout (seconds)
Enter the number of seconds that ColdFusion should wait for a response from the mail server.
Spool Interval (seconds)
Enter the number of seconds at which you want the mail server to process spooled mail.
Verify Mail Server Connection
To have ColdFusion verify that it can connect to your specified mail server after you submit this form, enable this option. You receive an error message if the connection fails.
Note: Whether or not you use this option, send a test mail message when you finish your mail settings.

Mail Logging Settings area

Select preferences for handling mail logs, as described in the following table:
Setting
Description
Error Log Severity
From the drop-down list box, select the type of SMTP-related error message to write to a log file. The options are: Debug, Warning, Debug, Information, and Error.
Log all e-mail messages sent by ColdFusion
Enable this option to save to a log file the To, From, and Subject fields of all e-mail messages.

ColdFusion MX writes sent mail and mail error logs to either of the following directories:

The following table describes the e-mail log files:
Log
Description
mailsent.log
Records sent e-mail messages
mail.log
Records general e-mail errors

Charting Settings page

The ColdFusion charting and graphing engine lets you produce highly customizable business graphics, in a variety of formats, using the cfchart tag. You use the Charting page in the Administrator to control characteristics of the engine.

The following table describes the caching and thread settings for the ColdFusion charting and graphing engine:
Setting
Description
Cache Type
Set the cache type. Charts can be cached either in memory or to disk. In memory caching is faster, but more memory intensive.
Maximum number of images in cache
Specify the maximum number of charts to store in the cache. After the cache is full, if you generate a new chart, ColdFusion discards the oldest chart in the cache.
Max number of charting threads
Specify the maximum number of chart requests that can be processed concurrently. The minimum number is 1 and the maximum is 5. Higher numbers are more memory intensive.
Disk cache location
When caching to disk, specify the directory in which to store the generated charts.

Java and JVM Settings page

The Java and JVM Settings page lets you specify the following settings, which enable ColdFusion MX to work with Java:
Setting
Description
Java Virtual Machine Path
The absolute file path to the location of the Java virtual machine (JVM): jvm.dll in Windows or jvm.so in Solaris, Linux, and HP-UX.
Initial Memory Size
The JVM initial heap size. Default is 8196 MB.
Maximum Memory Size
The JVM maximum heap size. Default is 512 MB.
Class Path
The file path(s) to the directories that contain the Java classes used by ColdFusion MX. Use a comma-delimited list for multiple entries; for example, c:\foo,d:bar
JVM Arguments
The arguments to the JVM. Use a space to separate multiple entries; for example, -Xint -Xincgc

Before ColdFusion saves your changes, it saves a copy of the current jvm.config file as jvm.bak. If you r changes prevent ColdFusion from restarting, use jvm.bak to restore your system. For more information, see the online Help.

Archives and Deployment page

The Archives and Deployment page includes tools that let you archive and deploy ColdFusion applications, configuration settings, data source information, and other types of information to back up your files quickly and easily. The complete list of archivable information includes the following:

After you archive the information, you can use the Administrator to deploy your web applications to the same ColdFusion MX server or to a ColdFusion MX server running on a different computer. Additionally, you can use these features to deploy and receive any ColdFusion archive file electronically.

The Archive Settings page in the Administrator lets you configure various archive system settings that apply to all archive and deploy operations. For more inforamtion, see the online Help.

Settings Summary page

The Settings Summary page shows all ColdFusion configuration settings. Click a group name to open that group's Administrator section, where you can edit settings.

Comments