How to configure a DataSource in JBoss?
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   elkin_pardo
Posted On:   Wednesday, August 11, 2004 12:22 PM

Hi! I have a problem with JBoss, I don't know how can I configure a DataSource for Oracle in Jboss, please I apreciate if you could help me.. which file or files I have to change..




Thanks in advance


Elkin Andres Pardo

Re: How to configure a DataSource in JBoss?

Posted By:   Anonymous  
Posted On:   Monday, August 30, 2004 12:46 PM

The jBoss datasource is a service like any mBean.
You should create a xml file in your server/application/conf or server/application/deploy directory that configures the data source.
The file should containt something like:







  

     myDatasource

    jdbc:mysql://localhost:3306/sSMS

    org.gjt.mm.mysql.Driver

     admin

     admin

     5

     20

    0

  





The name of this file should be terminated with -ds.xml, for instance mydatabase-ds.xml


Please note that the paramenters connection-url and driver-class refered in this sample are to a mySQL
database. For Oracle, that parameters should be something like this:


jdbc:oracle:thin:@localhost:1521:MYDB oracle.jdbc.driver.OracleDriver


Do not forget to include Oracle thin driver jar file in the classpath of you server or in the server/application/lib directory.

About | Sitemap | Contact