C H A P T E R 2 |
Performance Tuning |
This section provides tuning suggestions to assist you in obtaining the best performance from your Content Delivery Server system.
This chapter includes the following topics:
Configuration variables are used for the database connection pool size, memory settings, and database memory allocations. The values set for these variables can affect the performance of your system.
This section provides some guidelines for setting the configuration variables to improve performance.
The following table describes the connection pools used by Content Delivery Server. Pool ID is the string used to identify the pool in the configuration file.
Optimal performance is influenced by a number of factors, including the initial number and maximum number of database connections allowed. The $CDS_HOME/deployment/deployment-name/conf/DatabasePools.properties file contains the following properties for managing each pool, where pool-id is one of the pool IDs in TABLE 2-1:
Set these properties according to the guidelines in the following section. Changes take effect when Content Delivery Server is restarted.
To determine the optimal value for each property, consider the following parameters:
Number of subscribers accessing the system concurrently
Each database used for Content Delivery Server schemas must be configured to support the number of connections specified for each schema. Set the sessions parameter for the database to a number greater than the sum of connections specified. For example, given the following assumptions, set the sessions parameter to at least 54:
Changes take effect when Content Delivery Server is restarted.
To check whether the configured connection pool size is optimal, add a logger for DBPoolManager by adding the following statement to the $CDS_HOME/cfg/logging.properties file:
cds.DBPoolManager.level = ALL
If any of the following messages appear often in the log file when a Catalog Manager administrator, Vending Manager administrator, developer, or subscriber is accessing the system, it indicates that the maximum pool size is very low and a current thread (call) is waiting for other threads to release the connections:
Increase the value for the maximum size property based on the guidelines in Section 2.1.1.1, Determining the Pool Size.
If you are using WebLogic Server and you deployed all components to the same server, Content Delivery Server works well with 50% of a host’s memory assigned to the Java virtual machine. Reduce this value if the host is running database or other resource-intensive processes.
1. Edit the $CDS_HOME/deployment/deployment-name/bin/start_server.sh file.
2. Set the values for the JAVA_MEM variable to half the size of system memory.
For example, if system memory is 2 gigabytes, use the following statement:
export JAVA_MEM=”-ms1024m -mx1024m”
If more than three gigabytes of memory are assigned to the Java virtual machine, the virtual machine must be started in 64-bit mode.
Changes take effect when Content Delivery Server is restarted.
The optimal database configuration is dependent on many factors. Use the information provided in this section as a starting point for your database management and tuning.
For systems with up to 5000 items of content and 50 devices, use the following guidelines for memory allocation:
10 megabytes * the maximum number of database connections
See Section 2.1.1, Set the Database Connection Pool Size for information on database connections.
200 megabytes + the User Global Area (UGA)
UGA = 0.5 megabytes * the maximum number of database connections. See Section 2.1.1, Set the Database Connection Pool Size for information on database connections.
(10 megabytes * the maximum number of database connections) + UGA
UGA = 0.5 megabytes * the maximum number of database connections. See Section 2.1.1, Set the Database Connection Pool Size for information on database connections.
As more content or devices are added to your system, more memory might be required, especially for the buffer cache. Insufficient memory allocations might result in database error messages or slower performance.
See the Oracle web site (http://technet.oracle.com) for tips on tuning database performance.
Performance might also be improved by tuning your application server.
Set the following properties in the $CDS_HOME/deployment/deployment-name/conf/cache.config file to at least the number of items in the catalog. For example, if the catalog has 10,000 items, set the property to 10000 as shown.
Note - You might need to increase the heap size for the Java virtual machine to accommodate the larger cache. |
If you are using Sun Java System Application Server, disable the dynamic reloading of pages created using JavaServer Pages (JSP
) technology by adding the following statements to the $CDS_HOME/deployment/deployment-name/sun/domains/server-domain/applications/j2ee-modules/CDSSubscriberPortal/WEB-INF/sun-web.xml file and the $CDS_HOME/deployment/deployment-name/sun/domains/server-domain/applications/j2ee-modules/CDSFulfillmentManager/WEB-INF/sun-web.xml file.
<jsp-config> <property name="reload-interval" value="-1"/> </jsp-config>
See the Sun Java System Application Server web site (http://wwws.sun.com/software/sunone/) for additional tips on tuning Sun Java System Application Server.
Use the WebLogic Server console to set the following parameters as described:
If you are using WebLogic Server, disable dynamic reloading of web pages created using JSP technology by following these steps:
1. Change to the $CDS_HOME/deployment/deployment-name/weblogic/domains/domain-name/applications directory.
2. Edit each of the following files and set the param-name element pageCheckSeconds to -1 as shown in CODE EXAMPLE 2-1.
Changes take effect when Content Delivery Server is restarted.
See the WebLogic Server web site (http://www.weblogic.com/) for additional tips on tuning WebLogic Server.
Copyright © 2008, Sun Microsystems, Inc. All Rights Reserved.