Digging in to the code, I find org.jboss.resource.connectionmanager.BaseConnectionManager defines public void createPerUserPool(ManagedConnectionFactory factory, PoolParameters params)
and several of the Minerva ConnectionManagerFactories (conditionally) use this method. Am I on the wrong track here? If I can get a unique ConnectionPool for each Subject, with each pool configured for a different datasource, can I get most of the behavior I'm after? Thanks for the help, -Mike -----Original Message----- From: David Jencks [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 03, 2002 4:17 PM To: [EMAIL PROTECTED] Subject: Re: [JBoss-user] One bean, many datasources I suggest you use an idea Dain suggested to me, write a customized jca-jdbc wrapper that maps Subject to db url. (He suggested mapping subject to schema/catalog, however the same idea ought to work here.) If you want to combine result sets from several distinct databases I suggest you use a db that allows you to create views like this or modify your schema to have only one database, where each table includes a user id column. david jencks On 2002.04.03 17:33:23 -0500 "Simpson, Mike W" wrote: > Will JBoss3 allow me to specify multiple datasources for a single CMP > bean? > My app supports an asp model where I have physically separate databases, > each with identical schema, and users are bound to one database at logon. > It seems like a waste of resources to uniquely name instances of every > bean > (even if I need separate JNDI names to lookup from a specific datasource) > in > the system for each database when it doesn't really matter ultimately > which > datasource was used to populate the bean instance. > > Taken to the logical conclusion, it would be nice if my findBy... methods > could query many datasources and combine the resultsets, tracking > physical > database mappings on the back end. > > Has anyone had experience doing this? How can I get JBoss3 to let me > choose > the datasource for each instance of a bean rather than each class of > beans? > > -mike > > > > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> > <HTML><HEAD> > <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"> > > > <META content="MSHTML 5.50.4616.200" name=GENERATOR></HEAD> > <BODY> > <DIV><FONT face=Arial size=2>Will JBoss3 allow me to specify multiple > datasources for a single <SPAN class=828453422-03042002>CMP > </SPAN>bean? My app supports an asp model where I have physically > separate > databases, each with identical schema, and users are bound to one > database at > logon. It seems like a waste of resources to <SPAN > class=828453422-03042002>uniquely name</SPAN> instances of every bean > (even if I > need separate JNDI names to lookup from a specific datasource) in the > system for > each database when it doesn't really matter ultimately which datasource > was used > to populate the bean instance. </FONT></DIV> > <DIV><FONT face=Arial size=2></FONT> </DIV> > <DIV><FONT face=Arial size=2>Taken to the logical conclusion, it would be > nice > if my findBy... methods could query many datasources and combine the > resultsets, > tracking physical database mappings on the back end.</FONT></DIV> > <DIV><FONT face=Arial size=2></FONT> </DIV> > <DIV><FONT face=Arial size=2>Has anyone had experience doing this? > How can > I get JBoss3 to let me choose the datasource for each instance of a bean > rather > than each class of beans?</FONT></DIV> > <DIV><FONT face=Arial size=2></FONT> </DIV> > <DIV><SPAN class=828453422-03042002><FONT face=Arial > size=2>-mike</FONT></SPAN></DIV> > <DIV><SPAN class=828453422-03042002><FONT face=Arial > size=2></FONT></SPAN> </DIV> > <DIV><SPAN class=828453422-03042002><FONT face=Arial > size=2></FONT></SPAN> </DIV></BODY></HTML> > _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
