| Paul Ilechko 2007-03-16, 1:28 am |
| khash23@yahoo.com wrote:
> I just want to get some general understanding for the expected
> behavior of WebSphere when it comes to database connection pooling.
>
> Consider a scenario where an application connecting to a database
> reaches its max # of connection that's defined in WAS. What should
> be the behavior of the application server?s connection pooling and
> the applications using these pool to connect to the database. We have
> situation where the App Server crashes under this situation.
This should not happen. As Ken says, you should block on a connection
freeing up. Now, if you have application problems causing deadlocks, and
if you allow incoming requests to grow the number of threads without
limit, you will eventually run out of memory. If you have a crash, you
should be getting a heap dump and doing problem determination.
> Also, if the database has locking issues, what happens to the
> connections. Do they get released to the pool after certain time, or
> stay connected in which case you run out of connection objects.
Databases don't have locking issues - applications have locking issues.
A well written application should not require a large number of
connections, but tuning the thread pool and connection pool sizes in a
performance test environment, and fixing application problems that show
up while doing so, are an essential part of the development lifecycle.
|