Tuning WebLogic Server

Thread Count

You have some control over the number of threads in the default queue. Adding more threads will not necessarily improve performance, however. Generally speaking, you should allocate threads according to the following formula:

  • Allocate one thread per CPU on the server.

  • Add at least one additional thread. Add another addtional thread for every four CPUs.

If you suspect that your thread count is too low, examine your CPU utilization. Ideally, you want it to fluctuate between 85 and 100%. If utilization only rarely rises above 85%, consider adding a thread. If it stays pegged at or near 100%, remove a thread or two and see if you notice a performance improvement.

Thread Utilization

By default, one thread in three is allocated to read input from sockets. This may or may not be correct for your application. Socket reader threads are responsible for accepting client requests and passing them on to those threads that fulfill the requests .

Connection Pools

One of the biggest performance drains available is establishing and releasing a connection to the database. This problem has been somewhat alleviated by the creation of JDBC connection pools. A connection pool is a named collection of database connections accessible to client processes on a first-come-first- served basis. The connections in the pool are never released, so much of the overhead involved in traditional database interaction is avoided. See Chapter 7 for further discussion of connection pools.

Accepting Backlogs

If you notice that your server seems to be dropping a lot of connections, you can adjust the configuration to temporarily alleviate this problem. Expand the Servers folder and click on the particular server that you're concerned about. Click on the Tuning tab, and set the Accept Backlogs value to a higher number.

This will allow clients the dubious privilege of waiting in line for their turn at the CPU. Note that this is only a temporary stopgap. The underlying problem needs to be identified and corrected before your client processes take their business elsewhere.

Clusters

There's only so much that you can accomplish by configuration. If your CPU is never idle, there is little or no free memory, and application response time is poor, it's probably time to add another server and build a cluster. See Chapter 6 for further discussion of clusters.



BEA WebLogic Server Administration Kit
BEA WebLogic Server Administration Kit (Prentice Hall PTR Advanced Web Development)
ISBN: 0130463868
EAN: 2147483647
Year: 2002
Pages: 134
Authors: Scott Hawkins

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