cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrus Adamchik (JIRA)" <j...@apache.org>
Subject [jira] Reopened: (CAY-1536) Expand deserialization context to provide Injector object instead of just a DataChannel.
Date Sat, 19 Feb 2011 10:51:38 GMT

     [ https://issues.apache.org/jira/browse/CAY-1536?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Andrus Adamchik reopened CAY-1536:
----------------------------------


Issues with Tomcat 7.0.8 deserialization. Given a web app similar to Cayenne web tutorial
with a session containing a  DataContext with one object. When Tomcat is shutdown, the session
is serialized to disk. When tomcat is started and the page is reloaded in the browser with
the old session cookie, the following error occurs:


type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling
this request.

exception

org.apache.jasper.JasperException: java.lang.NullPointerException
	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:532)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:391)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
	org.apache.cayenne.configuration.web.CayenneFilter.doFilter(CayenneFilter.java:97)

root cause

java.lang.NullPointerException
	org.apache.cayenne.query.BaseQueryMetadata.resolve(BaseQueryMetadata.java:103)
	org.apache.cayenne.query.SelectQueryMetadata.resolve(SelectQueryMetadata.java:44)
	org.apache.cayenne.query.SelectQuery.getMetaData(SelectQuery.java:143)
	org.apache.cayenne.util.ObjectContextQueryAction.<init>(ObjectContextQueryAction.java:79)
	org.apache.cayenne.access.DataContextQueryAction.<init>(DataContextQueryAction.java:49)
	org.apache.cayenne.access.DataContext.onQuery(DataContext.java:999)
	org.apache.cayenne.access.DataContext.performQuery(DataContext.java:988)
	org.apache.jsp.index_jsp._jspService(index_jsp.java:69)
	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:417)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:391)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
	org.apache.cayenne.configuration.web.CayenneFilter.doFilter(CayenneFilter.java:97)



> Expand deserialization context to provide Injector object instead of just a DataChannel.
> ----------------------------------------------------------------------------------------
>
>                 Key: CAY-1536
>                 URL: https://issues.apache.org/jira/browse/CAY-1536
>             Project: Cayenne
>          Issue Type: Sub-task
>          Components: Core Library
>    Affects Versions: 3.1M2
>            Reporter: Andrus Adamchik
>            Assignee: Andrus Adamchik
>             Fix For: 3.1M2
>
>
> Replace BaseContext.bindThreadDeserializationChannel/getThreadDeserializationChannel
with a more generic context for deserialization : CayenneRuntime.bindThreadInjector/getThreadInjector.
This way deserialized objects can lookup any service in the runtime container. Will need to
test that in real scenarios (e.g. deserializing sessions from disk in Tomcat)

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message