There are several steps:
1) You need to tell JBoss about the datasource :
Tell JBoss to load the JDBC Driver by adding it to the list of jdbc.drivers
in JBoss.properties :
Insert an XADataSourceLoader service into JBoss.conf :
<MLET CODE="org.jboss.jdbc.XADataSourceLoader" ARCHIVE="jboss.jar"
CODEBASE="../../lib/ext/">
<ARG TYPE="java.lang.String" VALUE="MyORACLEds">
<ARG TYPE="java.lang.String"
VALUE="org.jboss.minerva.xa.XADataSourceImpl">
</MLET>
Insert the configuration information for this datasource into JBoss.jcml
(Setting the properties, i.e. URL as appropriate) :
<mbean name="DefaultDomain:service=XADataSource,name=MyORACLEds">
<attribute name="Properties"/>
<attribute name="URL">jdbc:oracle://localhost/JBoss</attribute>
<attribute name="GCMinIdleTime">1200000</attribute>
<attribute name="JDBCUser">sa</attribute>
<attribute name="MaxSize">10</attribute>
<attribute name="Password" />
<attribute name="GCEnabled">false</attribute>
<attribute name="InvalidateOnError">false</attribute>
<attribute name="TimestampUsed">false</attribute>
<attribute name="Blocking">true</attribute>
<attribute name="GCInterval">120000</attribute>
<attribute name="IdleTimeout">1800000</attribute>
<attribute name="IdleTimeoutEnabled">false</attribute>
<attribute name="LoggingEnabled">false</attribute>
<attribute name="MaxIdleTimeoutPercent">1.0</attribute>
<attribute name="MinSize">0</attribute>
</mbean>
If all goes well here, you should see your datasource in the startup logs.
2) Next you have to tell JAWS to use the datasource, (JAWS is the
persistence engine that CMP's use) :
Edit standardJAWS.xml and change the datasource and type-mapping entries :
<datasource>java:/MyORACLEds</datasource>
<type-mapping>Oracle8</type-mapping>
Hope this helps!
David Maddison
<< WILDFUSION >>
-----Original Message-----
From: vimal kansal [mailto:[EMAIL PROTECTED]]
Sent: 04 December 2000 18:41
To: [EMAIL PROTECTED]
Subject: [jBoss-User] BMP - How to setup database resource
Hi,
I am trying to deploy a BMP entity bean in jboss2.0.
But it appears that it always tries to goto
HypersonicSQL database, despite the fact that I have
tried to set it up to go against Oracle 8i. Can
somebody tell me what are the steps I need to follow
to set up the datasource correctly (I have tried
everything available in manual). Although I am able to
deploy a CMP bean correctlt to go against Oracle 8i.
TIA
__________________________________________________
Do You Yahoo!?
Yahoo! Shopping - Thousands of Stores. Millions of Products.
http://shopping.yahoo.com/
--
--------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]
--
--------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]