I have two sets of web applications that all run on the same Tomcat 5.5 server.
I have one common Realm defined in server.xml
:
<!-- Define the top level container in our container hierarchy -->
<Engine defaultHost="localhost" name="Catalina">
<Valve className="org.apache.catalina.authenticator.SingleSignOn" />
<Realm
className="com.key.portal.common.realm.PortalDataSourceRealm"
debug="0"
dataSourceName="jdbc/usa"
userTable="user_info"
userNameCol="username"
userIdCol="username"
userCredCol="password"
userInactiveCol="inactive"
userRoleTable="user_role"
roleNameCol="role" />
My "usa" applications both want to share a SingleSignOn with this datasource, and my "canada" applications to use singlesignon, but with a different datasource. (e.g. jdbc/canada
)
Is there a way I can split this top level Engine container into two divisions, or configure the applications to override the dataSourceName
? The tomcat docs say I can have exactly one "Engine" section defined.
But both sets of web applications want to use a different datasource to connect to it.