[jboss-user] [JBoss Seam] - Re: Change Database Connection at Runtime

bravefencer do-not-reply at jboss.com
Fri Sep 28 05:07:28 EDT 2007


thank you. 

But the problem is, that the Database Connection Information(url, password, username..) are retrievied at runtime of the application. so i can not configure a second, third.. database in a configuration file. 

at Application start i have the following databasase defined in JBoss-Beans.xml(i'm using tomcat 6.0 server) : 


<?xml version="1.0" encoding="UTF-8"?>

<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
            xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_1_0.xsd"
            xmlns="urn:jboss:bean-deployer">

   
      com.microsoft.sqlserver.jdbc.SQLServerDriver
      jdbc:sqlserver://localhost:1500;databaseName=Userdatabase
      user
      user
      java:/ZDBsource
      0
      10
      1000
      100000
      
      
      
    
   

   
      
         
      
   




This datasource will be queried to gain the Datasource Connection Information to another Database. At this point i must programatically establish the Connection to that second Database.





View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4089605#4089605

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4089605



More information about the jboss-user mailing list