Optimize with a SATA RAID Storage Solution
Range of capacities as low as $1250 per TB. Ideal if you currently rely on servers/disks/JBODs
Pooling resources (also called object pooling) among multiple clients is a technique used to promote object reuse and to reduce the overhead of creating new resources, resulting in better performance and throughput. Imagine a heavy-duty Java server application that sends hundreds of SQL queries by opening and closing connections for every SQL request. Or a Web server that serves hundreds of HTTP requests, handling each request by spawning a separate thread. Or imagine creating an XML parser instance for every request to parse a document without reusing the instances. These are some of the scenarios that warrant optimization of the resources being used.
Resource usage could prove critical at times for heavy-duty applications. Some famous Websites have shut down because of their inability to handle heavy loads. Most problems related to heavy loads can be handled, at a macro level, using clustering and load-balancing capabilities. Concerns remain at the application level with respect to excessive object creation and the availability of limited server resources like memory, CPU, threads, and database connections, which could represent potential bottlenecks and, when not utilized optimally, bring down the whole server.
In some situations, the database usage policy could enforce a limit on the number of concurrent connections. Also, an external application could dictate or restrict the number of concurrent open connections. A typical example is a domain registry (like Verisign) that limits the number of available active socket connections for registrars (like BulkRegister). Pooling resources has proven to be one of the best options in handling these types of issues and, to a certain extent, also helps in maintaining the required service levels for enterprise applications.
Most J2EE application server vendors provide resource pooling as an integral part of their Web and EJB (Enterprise JavaBean)
containers. For database connections, the server vendor usually provides an implementation of the DataSource interface, which works in conjunction with the JDBC (Java Database Connectivity) driver vendor's ConnectionPoolDataSource implementation. The ConnectionPoolDataSource implementation serves as a resource manager connection factory for pooled java.sql.Connection objects. Similarly, EJB instances of stateless session beans, message-driven beans, and entity beans are pooled in EJB containers
for higher throughput and performance. XML parser instances are also candidates for pooling, because the creation of parser
instances consumes much of a system's resources.
A successful open source resource-pooling implementation is the Commons Pool framework's DBCP, a database connection pooling component from the Apace Software Foundation that is extensively used in production-class enterprise applications. In this article, I briefly discuss the internals of the Commons Pool framework and then use it to implement a thread pool.
Let's first look at what the framework provides.
Archived Discussions (Read only)