When users start one of our tasks, then we always get the following error message with an additional stack trace (omitted here):

Error: Could not deserialize process data

asked 08.05.2009 at 07:50

Eric%20Wilhelm's gravatar image

Eric Wilhelm
(suspended)
accept rate: 0%


If a process execution reaches a task switch element, then Ivy automatically stores the current state of the process data in the System DB. With this feature we can guarantee that process executions are not lost after a planned server restart or even worse after a server crash.

To store the process data in the System DB we have to serialize it including all its members. Unfortunately we can only do this for Ivy data classes and Java classes that fulfill the Java Bean specification. If you have members in your process data whose type hat do not comply these scheme (e.g. Java interfaces), then you will get a serialization or deserialization exception. Unfortunately some of the PublicAPI classes cannot be serialized too, e.g. IUser.

You can avoid the problem if you do not use such classes or if you configure them to not be persistent. For the first solution, instead of using the user object (and thus the IUser interface that is not serializable) you use the name of the user directly. For the second solution, go to the data class editor for the problematic data class and change the entry in the column Persistent to No.

link

answered 11.05.2009 at 08:41

MichaelD%C3%A4nzer's gravatar image

MichaelDänzer ♦
(suspended)
accept rate: 86%

Hallo

Ich hatte eine List(IRole) in den Daten Klassen als persistent definiert.

Nach dem ich das auf nicht persitent gesetzt habe funktioniert es.
Danke

mfG
Eric Wilhelm


> Guten Tag
>
> Bei einem Aufgabenwechsel oder Rollenübergang oder allgemein bei einem Taskswitch wird der Prozesszustand persistiert d.h. in die System-Datenbank geschrieben. Damit kann sichergestellt werden, dass bei einem Fehler der letzte Zustand wiederhergestellt werden kann.
>
> Ich vermute, dass Sie in dem Prozess irgendwo in der Datenklasse einen Typ benutzen, der nicht serialisierbar ist (oder im Java Jargon das Interface Serializable nicht implementiert). Leider trifft das auch für einige der Klassen zu, die in der Ivy API verwendet werden wie z.B. IUser.
>
> Den Fehler können Sie nur vermeiden indem Sie solche Klassen aus der Datenklasse herausnehmen oder im Editor den Eintrag unter "Persistent" auf "No" stellen, die Felder mit dieser Einstellung werden bei einem TaskSwitch dann nicht persisitiert. Als Workaround können Sie falls Sie nur eine oder einige der Eigenschaften der fraglichen Klasse brauchen, diese in die Prozess-Datenklasse schreiben. Also, z.B. statt in.myUser dann in.myUserName und in.myUserEmail verwenden.
>
> Ich hoffe, dies hilft weiter.
>
> Mit freundlichen Grüssen
> Michael Dänzer
> IvyTeam Support
>
> > Hallo
> >
> > Ich habe mit dem Control Task eine Übergabe von Rolle 1 nach Rolle 2 erstellt.
> > Wenn die Rolle 2 in Ihrer "Personal Task List" die zugewiesen Aufgabe startet erhalte ich die Fehlermeldung:
> >
> > Error: Could not deserialize process data
> > ch.ivyteam.ivy.request.RequestException: Could not deserialize process data
> > at ch.ivyteam.ivy.webserver.internal.IvyServlet.doRespondAsSystem(IvyServlet.java:326)
> > at ch.ivyteam.ivy.webserver.internal.AbstractServlet$2.call(AbstractServlet.java:187)
> > at ch.ivyteam.ivy.security.internal.SecurityManager.executeAsSystem(SecurityManager.java:1394)
> > at ch.ivyteam.ivy.webserver.internal.AbstractServlet.doGet(AbstractServlet.java:182)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> > at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
> > at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> > at ch.ivyteam.ivy.webserver.internal.IvyFilter.doFilterAsSystem(IvyFilter.java:271)
> > at ch.ivyteam.ivy.webserver.internal.IvyFilter.access$100(IvyFilter.java:36)
> > at ch.ivyteam.ivy.webserver.internal.IvyFilter$2.call(IvyFilter.java:182)
> > at ch.ivyteam.ivy.webserver.internal.IvyFilter$2.call(IvyFilter.java:180)
> > at ch.ivyteam.ivy.security.internal.SecurityManager.executeAsSystem(SecurityManager.java:1394)
> > at ch.ivyteam.ivy.webserver.internal.IvyFilter.doFilter(IvyFilter.java:176)
> > at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
> > at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> > at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
> > at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
> > at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
> > at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
> > at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
> > at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
> > at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
> > at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
> > at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
> > at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
> > at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
> > at java.lang.Thread.run(Thread.java:595)
> > Caused by: ch.ivyteam.ivy.persistence.PersistencyException: Could not deserialize process data
> > at ch.ivyteam.ivy.workflow.internal.processdatacache.ProcessData.deserialize(ProcessData.java:246)
> > at ch.ivyteam.ivy.workflow.internal.processdatacache.ProcessModelVersionProcessDataCache.getStartProcessData(ProcessModelVersionProcessDataCache.java:154)
> > at ch.ivyteam.ivy.workflow.internal.processdatacache.ProcessModelVersionProcessDataCache.cacheStartProcessDataAsCurrentProcessData(ProcessModelVersionProcessDataCache.java:288)
> > at ch.ivyteam.ivy.workflow.internal.processdatacache.ProcessDataCache.cacheStartProcessDataAsCurrentProcessData(ProcessDataCache.java:149)
> > at ch.ivyteam.ivy.workflow.internal.Task.resume(Task.java:2138)
> > at ch.ivyteam.ivy.workflow.internal.WorkflowSession.resumeTask(WorkflowSession.java:357)
> > at ch.ivyteam.ivy.workflow.internal.WorkflowSession$4.execute(WorkflowSession.java:339)
> > at ch.ivyteam.ivy.workflow.internal.WorkflowSession$4.execute(WorkflowSession.java:336)
> > at ch.ivyteam.ivy.persistence.base.AbstractPersistencyService.execute(AbstractPersistencyService.java:94)
> > at ch.ivyteam.ivy.persistence.base.ClassPersistencyService.execute(ClassPersistencyService.java:592)
> > at ch.ivyteam.ivy.workflow.internal.WorkflowManager.execute(WorkflowManager.java:1123)
> > at ch.ivyteam.ivy.workflow.internal.WorkflowSession.execute(WorkflowSession.java:373)
> > at ch.ivyteam.ivy.workflow.internal.WorkflowSession.resumeTask(WorkflowSession.java:334)
> > at ch.ivyteam.ivy.webserver.internal.IvyServlet.findTask(IvyServlet.java:1247)
> > at ch.ivyteam.ivy.webserver.internal.IvyServlet.processProcessRequest(IvyServlet.java:511)
> > at ch.ivyteam.ivy.webserver.internal.IvyServlet.doRespondAsSystem(IvyServlet.java:235)
> > ... 27 more
> > Caused by: java.io.IOException: Unexpected char r
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readObjectRaw(IvyScriptDeserializer.java:119)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readJavaFields(IvyScriptDeserializer.java:318)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readObjectRaw(IvyScriptDeserializer.java:128)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readCollection(IvyScriptDeserializer.java:636)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readObjectRaw(IvyScriptDeserializer.java:189)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readJavaFields(IvyScriptDeserializer.java:318)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readObjectRaw(IvyScriptDeserializer.java:201)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readJavaFields(IvyScriptDeserializer.java:318)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readObjectRaw(IvyScriptDeserializer.java:201)
> > at ch.ivyteam.ivy.scripting.serialization.IvyScriptDeserializer.readObject(IvyScriptDeserializer.java:87)
> > at ch.ivyteam.ivy.workflow.internal.processdatacache.ProcessData.deserialize(ProcessData.java:208)
> > ... 42 more
> >
> >
> > mfG
> > Eric Wilhelm
link

answered 11.05.2009 at 09:59

MichaelD%C3%A4nzer's gravatar image

MichaelDänzer ♦
(suspended)
accept rate: 86%

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×68

Asked: 08.05.2009 at 07:50

Seen: 12,245 times

Last updated: 08.05.2009 at 07:50