Opened 15 years ago
Closed 15 years ago
#1356 closed defect (fixed)
Blank page when listing wells for a plate.
Reported by: | Martin Svensson | Owned by: | Martin Svensson |
---|---|---|---|
Priority: | major | Milestone: | BASE 2.13 |
Component: | web | Version: | trunk |
Keywords: | Cc: |
Description
Related exception in the tomcat-log
org.hibernate.LazyInitializationException: could not initialize proxy - no Session at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:132) at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174) at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190) at net.sf.basedb.core.data.ReporterData_$$_javassist_35.getName(ReporterData_$$_javassist_35.java) at org.apache.jsp.lims.plates.wells.list_005fwells_jsp._jspService(list_005fwells_jsp.java:1650) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:374) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at net.sf.basedb.clients.web.servlet.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:70) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) at java.lang.Thread.run(Thread.java:619)
Change History (3)
comment:1 by , 15 years ago
comment:2 by , 15 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:3 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Note:
See TracTickets
for help on using tickets.
I think this is is related to the change in [5026] (ticket:1350) which changed the laziness of reporters to
lazy="true"
.The problem is also related to the code in
Well.getReporter()
whichevict()
:s the reporter from the session before returning it. Thus, there is no session when Hibernate wants to lazily initialize the reporter. The reporter must be evicted since we don't want it to be possible to update reporter properties without a batcher.We could solve this by forcing initialization of the reporter inside the
Well.getReporter()
method, but it is not always that we want it to be initialized. For example, if we only need to reporter id or need to create a link to the same reporter.A better solution in this case is probably to force a
left join fetch
in the query in thelist_wells.jsp
page. There is already a left join, but the last parameter should be changed from false to true.But I also think we need the other option of forcing an initialization of the reporter, but we should probably overload the
Well.getReporter()
method with aWell.getReporter(boolean forceInitialization)
for this.