Announcement Announcement Module
Collapse
No announcement yet.
Newbie Question : Multiple connection to database with different username and pass Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Newbie Question : Multiple connection to database with different username and pass

    I am really sorry; but, I am seriously in trouble and really appreciate any clue.
    I am working with Wavamker (http://www.wavemaker.com/), which is based on the Spring framework. Wavemaker creates one connection to database and I need to have multiple connection for different user/pass. I am looking for a way to see whether there is a way to do it through Spring. This is the big picture of how Wavemaker communicate to database via spring :

    Browser <--- (Session ID) ---> Spring <--- (Tenant ID to user/pass) ---> Wavemaker <-------> spring <.....> Hibernate <.....>JDBC <........> Database

    I know that there is a "dbname.spring.xml" file, which has all the beans and related classes to connect to database(I attached it here with doc extension). In this xml file, I think that I must replace class "DriverManagerDataSource" with my own class, which creates multiple connection to database for each usernname .; but, there is no User/Session between wavemaker and database; so, I can pass them to "DriverManagerDataSource" ; but, Wavamaker does not have them when it connects to database, and I do not know how to get it. Is it possible that somehow I use Spring to golobally save and define user and session id or in some way have them when my app needs to connect to databse; please give me a clue . My boss insists that it is possible through Spring; but, I have no idea how!
Working...
X