Removing HSQLDB
JBoss 3.2 and 4.0.x
remove the descriptor for the HSQLDB datasource DefaultDS by deleting deploy/hsqldb-ds.xml;
in conf/login-config.xml, comment out the <application-policy> declaration with the name "HsqlDbRealm";
remove the HSQLDB libraries by deleting lib/hsqldb.jar and lib/hsqldb-plugin.jar.
Several services rely on the datasource:
JBossMQ;
EJBTimerService;
HiLoGenerator.
After removing the datasource you should either:
configure another datasource with the JNDI name DefaultDS;
go through all the references in the various descriptors and change them to reference another datasource.
JBoss AS 5.x.x
- Remove the libraries hsqldb.jar and hsqldb-plugin.jar from jboss/common/lib/.
- Copy the necessary driver libraries for the new dbms to the directory jboss/server/xxx/lib/.
- Create a database and users with enough rights for this database.
- Modify the application-policy HsqlDbRealm in jboss/server/xxx/conf/login-config.xml. Configure the username and password for the database. Rename it. For example MySqlDbRealm.
- Remove the data source jboss/server/xxx/deploy/hsqldb-ds.xml which has DefaultDS as jndi name and create a new local-tx data source with DefaultDS as jndi name in directory jboss/server/xxx/deploy/. Examples could be found in jboss/docs/examples/jca/.
Add to the new data source <transaction-isolation>TRANSACTION_READ_COMMITTED</transaction-isolation> and add the <security-domain>xxxDbRealm</security-domain> which you defined in jboss/server/xxx/conf/login-config.xml - Modify jboss/server/xxx/conf/standardjbosscmp-jdbc.xml so that the <datasource-mapping> has the correct mapping and set <fk-constraint> on true, if your db could handle foreign keys
- Remove jboss/server/xxx/deploy/messaging/hsqldb-persistence-service.xml and create a new xxx-persistence-service.xml. Examples could be found in jboss/docs/examples/jms/.
Make sure that <depends optional-attribute-name="ChannelFactoryName">jboss.jgroups:service=ChannelFactory</depends> is replaced by <attribute name="ChannelFactoryName">jboss.jgroups:service=ChannelFactory</attribute> (see jira JBAS-6333 and JBAS-6991)
Comments