I am currently working on a web application running on a mutualised WebSphere. This application uses a datasource (shared with other applications) and persistent EJB Timer.
Since the EJB Timer are persistent, WebSphere uses its own datasource in order to persist the EJB Timer state into the database. (Used for internal management of WebSphere)
Application's EJB Timer call DAO my "create method".
All are managed with JTA transactions.
I would like to find the best "strategy" to apply regarding datasources. After several searches on the Internet I am still in the dark.
How to configure datasources?
- Should two datasources be used in XA?
- Is it possible to use a non-XA datasource for the management of my EJB Timer (WebSphere) and XA datasource for the processing done in my EJB (create method)?
In my opinion, all datasources should be in non XA...
What is the best practice when we using datasource in a mutualised environment, is it necessary to use one datasource (pointing to the same DB) per application or to have only one datasource per DB?
Thanks a lot :)
I'm not certain what you mean by 'mutualised' WebSphere, but I'll assume you mean an instance of the app server with multiple applications running. Your questions: