5 Designing JDBC Applications for Performance Optimization

5
Designing JDBC Applications for Performance Optimization
Developing performance-oriented JDBC applications is not easy. JDBC drivers do not throw exceptions to tell you when your code is running too slow. This chapter presents some general guidelines for improving JDBC application performance that have been compiled by examining the JDBC implementations of numerous shipping JDBC applications. These guidelines include:
■
■
■
■
Following these general guidelines can help you solve some common JDBC system performance problems, such as those listed in the following table.
Evaluation of complex SQL queries on the database server is slow and can reduce concurrency.
Excessive calls from the application to the driver slow performance.
In addition, most JDBC drivers provide options that improve performance, often with a trade-off in functionality. If your application is not affected by functionality that is modified by setting a particular option, significant performance improvements can be realized.