I have been tinkering with JForum quite a bit to tie it into an existing web-app.
I wanted to add some new DAO classes, so I subclassed the net.jforum.dao.mysql.MysqlDataAccessDriver, and changed mysql.properties
dao.driver=org.2wav.dao.mysql.MyDataAccessDriver
The code builds, org.2wav.dao.mysql.MyDataAccessDriver appears to be in the WEB-INF/classes directory.
In JForumBaseServlet.java, this code now throws a NoClassDefFoundException:
// Start the dao.driver implementation
DataAccessDriver.init((DataAccessDriver)Class.forName(
SystemGlobals.getValue(ConfigKeys.DAO_DRIVER)).newInstance());
I suspected something is wrong with my custom DataAccessDriver, however, when I change dao.driver back to the original settings,
i get the same class def error. Code that worked before is now busted. I have restarted
tomcat, and even tried changing the code to directly instantiate net.jforum.dao.mysql.MysqlDataAccessDriver but that throws java.lang.ExceptionInInitializerError.
Any ideas what I might have broken, that JForumBaseServlet.init no longer can load dao.driver? [originally posted on jforum.net by 2wav]