31.01.06

JavaBlackBelt.com ErrorMessage: Spring/Struts/Hibernate

I just registered at JavaBlackBelt.com and one of the first things was an error :Apache Tomcat/5.5.9 - Error report at javablackbelt.com
So they are running on Tomcat 5.5.9 and use the OpenSessionInViewFilter provided by Spring, running Tiles/Struts and Hibernate. Nice StackTrace:

javax.servlet.jsp.JspException: ServletException in '/WEB-INF/jsps/common/fragments/header.jsp': Could not open Hibernate Session for transaction; nested exception is net.sf.hibernate.exception.JDBCConnectionException: Cannot open connection org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:921) org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:460) org.apache.jsp.WEB_002dINF.jsps.common.templates.main_jsp._jspx_meth_tiles_insert_0(org.apache.jsp.WEB_002dINF.jsps.common.templates.main_jsp:301) org.apache.jsp.WEB_002dINF.jsps.common.templates.main_jsp._jspService(org.apache.jsp.WEB_002dINF.jsps.common.templates.main_jsp:224) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056) org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:261) org.apache.struts.tiles.TilesRequestProcessor.processTilesDefinition(TilesRequestProcessor.java:237) org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:300) org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:231) org.apache.struts.action.ActionServlet.process(ActionServlet.java:1164) org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:397) javax.servlet.http.HttpServlet.service(HttpServlet.java:689) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056) org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:261) org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:388) org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:316) org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:231) org.apache.struts.action.ActionServlet.process(ActionServlet.java:1164) org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:397) javax.servlet.http.HttpServlet.service(HttpServlet.java:689) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) be.loop.jbb.web.filter.CompressionFilter.doFilter(CompressionFilter.java:60) be.loop.jbb.web.filter.LoginFilter.doFilter(LoginFilter.java:84) org.springframework.orm.hibernate.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:174) org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) be.loop.jbb.web.filter.ProxyEncodeFilter.doFilter(ProxyEncodeFilter.java:26)

Posted by Karsten at 17:06 | Comments (1) | TrackBack

30.01.06

Hibernate 3.1 and Spring 2.0?

I wonder when is the right time to migrate from Hibernate 3.0.5 to Hibernate 3.1.x (see hibernate.org - Hibernate3 Migration Guide) and from Spring 1.2.x to 2.0?
Has anyone acomplished this migration? I know that Spring is just in the Milestones Release phase but they plan to release the final version in Spring ;) I guess. And Hibernates seams to get stable on their 3.1 branch.
Are there any issues migrating to the new Hibernate jar only? I saw something in Spring's JIRA (http://opensource2.atlassian.com/projects/spring/browse/SPR-1354) but it seams like Spring just doesn't care about this upgrade, which would be nice.
So I might give the new Hibernate Release a try first and update Spring later in a couple of month.

Posted by Karsten at 09:14 | Comments (2) | TrackBack