dimanche 29 mars 2015

Spring: Initialize multiple connection pools at startup

I want to initialize multiple connection pools at context startup by reading connection parameters from a database table. Basically I want to address following two things




  1. Read connection properties from database not the properties file.




  2. Their are multiple connection pool(rows in db) details.




So my question is How can I iterate over list of rows returned by database in spring-context file and create multiple data-source objects and store them (Lets say in a map) with a unique key?


Let me know if more details are needed. Thanks.


Aucun commentaire:

Enregistrer un commentaire