Chapter 10 Achieving Optimum Performance with PowerDynamo


Performance requirements

PowerDynamo includes features that have been specially designed to ease creation and optimization of high volume Web sites.

Dynamo Web sites may experience slowdowns due to one or all of the following reasons:

Script processing

As a general rule, a Web document should take no longer to execute than the time between requests to the Web site. For example, if a Web site has an average of one request every three seconds, each Web document should take no longer than three seconds to execute from start to finish.

Figure 10-1 illustrates how the length of time required to execute a script increases as the load on the Web server increases.

Figure 10-1: Relationship between load and processing time

Note  

The ideal script design
This section describes the ideal design where each script is the only request being processed at any time. In reality, multiple requests arrives simultaneously for processing by the Web site. PowerDynamo's multithreaded architecture allows for efficient processing of these scripts.

If only one Web document is being executed by PowerDynamo, 100% of Dynamo's CPU time may be available for the processing of that document. This results in the shortest possible execution time of a document. When two or more documents are being processed concurrently, CPU time is shared. The sharing of CPU time increases the time required to complete the request. If the average volume of requests is once every two seconds and the average document takes three seconds to execute, a backlog is created as each subsequent request takes longer to execute.

For more information on minimizing the processing time of your scripts, see "Writing cacheable documents" and "Scheduling your scripts".

For more information about running PowerDynamo on a multiple processor system, see "Load balancing".

Minimizing the calls to the database

Another cause for performance degradation is the time required to execute queries against the database. PowerDynamo does not have control over the time required to issue a query, but it does provide ways to control the number of times a database is accessed.

Setting an efficient document cache size as well as defining cachedOutputTimeOut values where appropriate can significantly minimize the number of calls to a database. Additional improvements can be made to the efficiency of a Web site by scheduling certain documents to execute on a special time frame.

If you do not optimize scripts and minimize database calls when you create a high-volume Web site, you may experience the time lag demonstrated in the first time line in Figure 10-2.

Figure 10-2: Optimizing scripts

For more information about minimizing calls to your database, see "Optimizing your document cache".

Working with Connections to increase performance

The third most common cause of performance degradation is the creation and use of connections within a Web site. Connections are the link between users and the information that they request from a Web site. Each time a user makes a request to a dynamic Web site, connections are created, and require costly processing time.

With minimal effort from the Web author, PowerDynamo can optimize its connections and work with them in such a way that required processing time for creating connections need not be an issue to the performance of the Web site.

For more information about working with connections, see "Working with connections".

 


Copyright © 2001 Sybase, Inc. All rights reserved.