2 Replies Latest reply on Apr 29, 2003 8:59 AM by anupj

    EJB's and Default DataSource

    Charles Arcudi Newbie

      I'm running through a set of ejb examples, all of which will be (by default) run using the default HyperSonic DB, which is not exactly optimum from a DB management , query, etc. standpoint.

      All I'd like to do is automatically point the current application to an alternative DB (MySQL, Oracle) and use it by default rather than the JBoss "default." I've got a set of jboss-service.xml files I can use (whether embedded in the app or in the <server-config>/deploy directory.

      Can this be done through deployment descriptors, without resorting to a coded JNDI lookup in every bean (even entity beans)?

      The samples I've used before with embedded jboss-service.xml files included resource-refs in the jboss.xml and ejb-jar.xml files, and for all that, each bean still had to get a handle to the DS and run off that pool of connections. Not really practical in a CMP-managed app.

      Any suggestions?