0 Replies Latest reply on Oct 10, 2003 10:38 AM by stevehw

    datasource-mapping in jbosscmp-jdbc

    stevehw

      Hi,

      Forgive me as an EJB newbie. I am using JBoss 3.2.1 and have created an EJB which is successfully working from a MySql database.

      I am confused as to why the datasource-mapping entity exists in the jbosscmp-jdbc.xml file packaged with my bean. Does this not couple my bean to MySql? Can I specify the datasource mapping in the mysql-ds.xml deployed in the cluster, thus abstracting the database type from my bean?

      On a side note, the remove-table entity in jbosscmp-jdbc.xml removes the tables on JBoss shutdown. Is there a mechanism to remove the tables on un-deploy? With the current behaviour, why does create-table not drop and create the tables on startup?

      Kind Regards,

      Steve HW.