Question

I'm new to google app engine and I'm trying to deploy a spring application with spring web flow in google app engine. My application works in localhost with the app engine development environment. However when I deploy the application with app engine I get the following error message.

Appreciate if someone could advise to solve this issue.

javax.servlet.ServletException: java.lang.RuntimeException: java.io.InvalidClassException: org.springframework.webflow.conversation.impl.ConversationContainer; local class incompatible: stream classdesc serialVersionUID = -612159325924033885, local class serialVersionUID = 5598780395474023335

I have tried searching for an answer and so far I haven't been able to fix this issue.

Following are the jar files I have in WEB-INF/lib currently.

all-themes-1.0.10.jar
appengine-api-1.0-sdk-1.8.9.jar
appengine-api-labs.jar
appengine-endpoints-deps.jar
appengine-endpoints.jar
appengine-jsr107cache-1.8.9.jar
commons-logging-1.1.1.jar
el-ri-1.0.jar
jsf-api-2.1.26.jar
jsf-impl-2.1.26.jar
jsr107cache-1.1.jar
primefaces-4.0.jar
spring-aop-3.2.6.RELEASE.jar
spring-beans-3.2.6.RELEASE.jar
spring-binding-2.3.2.RELEASE.jar
spring-context-3.2.6.RELEASE.jar
spring-core-3.2.6.RELEASE.jar
spring-expression-3.2.6.RELEASE.jar
spring-faces-2.3.2.RELEASE.jar
spring-js-2.3.2.RELEASE.jar
spring-web-3.2.6.RELEASE.jar
spring-webflow-2.3.1.RELEASE.jar
spring-webflow-2.3.2.RELEASE.jar
spring-webmvc-3.2.6.RELEASE.jar

Ive also tried to use latest jar files for webflow and spring but nothing seems to workout.

Error Message:

javax.servlet.ServletException: java.lang.RuntimeException: java.io.InvalidClassException: org.springframework.webflow.conversation.impl.ConversationContainer; local class incompatible: stream classdesc serialVersionUID = -612159325924033885, local class serialVersionUID = 5598780395474023335
at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:268)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:923)
at com.google.apphosting.runtime.jetty.RpcRequestParser.parseAvailable(RpcRequestParser.java:76)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:146)
at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:446)
at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:437)
at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:444)
at com.google.tracing.CurrentContext.runInContext(CurrentContext.java:188)
at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:308)
at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:300)
at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:441)
at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:251)
at java.lang.Thread.run(Thread.java:724)
Caused by: java.lang.RuntimeException: java.io.InvalidClassException: org.springframework.webflow.conversation.impl.ConversationContainer; local class incompatible: stream classdesc serialVersionUID = -612159325924033885, local class serialVersionUID = 5598780395474023335
at com.google.apphosting.runtime.SessionManagerUtil.deserialize(SessionManagerUtil.java:57)
at com.google.apphosting.runtime.jetty.DatastoreSessionStore.createSessionFromEntity(DatastoreSessionStore.java:58)
at com.google.apphosting.runtime.jetty.DatastoreSessionStore.getSession(DatastoreSessionStore.java:84)
at com.google.apphosting.runtime.jetty.SessionManager.loadSession(SessionManager.java:327)
at com.google.apphosting.runtime.jetty.SessionManager.getSession(SessionManager.java:301)
at org.mortbay.jetty.servlet.AbstractSessionManager.getHttpSession(AbstractSessionManager.java:237)
at org.mortbay.jetty.servlet.SessionHandler.setRequestedId(SessionHandler.java:246)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:136)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418)
at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:266)
... 16 more
Caused by: java.io.InvalidClassException: org.springframework.webflow.conversation.impl.ConversationContainer; local class incompatible: stream classdesc serialVersionUID = -612159325924033885, local class serialVersionUID = 5598780395474023335
at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:592)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1649)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1562)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1798)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1395)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:396)
at java.util.HashMap.readObject(HashMap.java:1043)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1004)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1914)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1819)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1395)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:396)
at com.google.apphosting.runtime.SessionManagerUtil.deserialize(SessionManagerUtil.java:55)
... 26 more
Was it helpful?

Solution

The problem is likely with the session objects that are already existing in your live App Engine application. It seems that there are several objects created over there of type ConversationContainer and the JARs that you have subsequently linked up contain some differences in terms of Serialization UID, which is causing an issue.

The choices before you would be to try these methods and see which one works:

  • If possible, ensure that previous Serialization UID used for your classes is the same. I believe leaving them empty might also work.

  • Look at the Sessions Datastore in your App Engine instance, see if it is possible to clear that along with possible MemCache entries that are holding objects of that type.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top