O'Reilly logo

Java Programming with Oracle JDBC by Donald Bales

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 7.  JNDI and Connection Pooling

An object-oriented programming language derives its strength from two areas. First, you have the constructs of the programming language itself that allow you to write well-structured objects to extend that language. Second, you have the extensive libraries of APIs that have been written to provide standard functionality. Think for a moment about how APIs are created. A software engineer does not just wake up one morning and have an entire API worked out in every detail. Instead, an API’s design is based on the experiences of professionals like you, who, over time, have gained insight through problem solving as to what is needed in an API to make it a useful part of developing an application. Accordingly, over time, an API evolves through this community process to better fit the needs of the programming community.

When it comes to the JDBC API, specifically the DriverManager facility, there is an evolution taking place. In Chapter 4, we needed to put a significant amount of code around DriverManager to implement a sharable connection facility. It took even more work to make our sharable connections cacheable. With the Java 2 Enterprise Edition (J2EE), a framework has been defined for sharing and caching connections. This framework is the JDBC 2.0 Extension API. In this chapter, we’ll cover the JDBC 2.0 Extension API, which is a another set of JDBC interfaces, along with Oracle’s implementation of these interfaces. We’ll also look at a functional ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required