Consider a hypothetical application that needs to be deployed on a single app server and has to service mulitple clients. Consider that there is a database per client. Thus n databases for n clients. However, all of these database have the same structure, and only the content varies.
Now to the problem:
Can I use CMP's in this context where I need to connect to different databases(with absolutely identical structure)
for each client. Different databases mean different Datasources, hence how do I uniquely associate a CMP Entity Bean with a single table for a particular datasource. Also, we do not want a different entity bean set for each database!
Also multiple application instances are not alloweded to be deployed on the server(s).
E.g. Say, clients jerry, larry and harry, use my application. Each one has his own database say jerryDb, larryDb and harryDb, these are also their datasource jndi names.
The databases ofcourse have an identical structure, just that they are named differently. Since I want to keep only one instance of application deployed, is it possible to use CMP Entity beans, and service all the three clients with their respective data.
Regards,
Swatkat
-
Changing a Datasource at runtime( CMP Entity beans) (1 messages)
- Posted by: Binoy Shah
- Posted on: October 18 2003 05:32 EDT
Threaded Messages (1)
- Changing a Datasource at runtime( CMP Entity beans) by Slava Imeshev on October 28 2003 14:49 EST
-
Changing a Datasource at runtime( CMP Entity beans)[ Go to top ]
- Posted by: Slava Imeshev
- Posted on: October 28 2003 14:49 EST
- in response to Binoy Shah
Swatkat,
It's not possible to change CMP datasources on the fly. You will have to deploy the application per client database.
Regards,
Slava Imeshev