tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jukka Ruohonen <>
Subject A pool question
Date Mon, 25 Feb 2013 08:52:44 GMT

A question related to pools. Background: a big application in which it is
preferable to enforce different roles for different databases and tables. 
This implies that there are different user names and passwords for different
connections. As I understand, there are two options for connection pooling
in a scheme like this:

	A. Create different resources for the different roles, each having
	   the user names and passwords defined as constants in the Tomcat
	   configuration files.

	B. Group the different roles into a bigger scheme and use the option
	   'alternateUsernameAllowed' to obtain the connections with the
	    specific user names and passwords.

Both were tested to work. But I wonder:

	1. The first option seems intuitively more efficient. But on the
	   other hand, does each Resource define its own cleaner thread?
	   I wouldn't want to overburden the setup with too many threads.

	2. Are there any benchmarks on the option B? The plain FIFO seems
	   rather inefficient if there are many different users/passwords.

Any additional thoughts?

- Jukka.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message