Resource Pooling
Popular Web applications have to deal with hundreds or thousands of requests in parallel, many of which rely on application and database resources. The overhead of providing access to these resources can balloon quickly as parallelism demands rise. Consider highly concurrent database access. Each client that wants to use the database will require a database connection. Each connection requires the overhead of memory to store its state and also the overhead to create and initialize it. When you're talking about hundreds or thousands of database clients, this overhead can become unmanageable.
One very common technique to reduce overhead is resource pooling—in this case, pooling database connections. The idea here is that it's cheaper ...
Get Building Scalable and High-Performance Java™ Web Applications Using J2EE™ Technology now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.