Re: [jboss-user] [JBoss Microcontainer Development] - Making JavassistTypeInfo serializable
by David Lloyd
David Lloyd [http://community.jboss.org/people/david.lloyd%40jboss.com] replied to the discussion
"Making JavassistTypeInfo serializable"
To view the discussion, visit: http://community.jboss.org/message/535046#535046
--------------------------------------------------------------
> Kabir Khan wrote:
>
> Looking at https://jira.jboss.org/jira/browse/JBREFLECT-16 https://jira.jboss.org/jira/browse/JBREFLECT-16 I wanted to do the same as I did to make the reflect flavour properly serializable, which was simply to add this to ClassInfo, as mentioned here http://community.jboss.org/message/534270#534270:
> [...]
> If I do the same for JavassistTypeInfo, then that will load the class. Is that a bad thing? Probably...
>
> The alternative for this simple implementation to work is to save the name and the classloader, and classloaders are not serializable.
>
> Or am I missing something? When deserializing a class should that happen in the same classloader (or one with access to similar classes if serialized out of the vm) as the one that serialized it in the first place? If the answer is yes, then I can go forward with this.
>
Yes, it +should+, however that is really up to the serialization implementation to get right. In most cases, folks just use the thread's context classloader or just one static classloader for deserialization. Perhaps in our modular future, we'll see a trend of classes being annotated with identifiers which will locate the correct corresponding classloader on the receiving side.
In other words... don't sweat it, it should be OK.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/535046#535046]
Start a new discussion in JBoss Microcontainer Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 7 months
[jBPM] - Async Fork Transaction Issues
by Rachel Hodos
Rachel Hodos [http://community.jboss.org/people/rhodos] created the discussion
"Async Fork Transaction Issues"
To view the discussion, visit: http://community.jboss.org/message/535039#535039
--------------------------------------------------------------
Hi,
I am trying to get an async fork test process working on jBPM 4.3. I am using the HSQLDB with the default configuration except that the job executor is activated to allow concurrency. The process just forks into two custom nodes, A and B, where their names should be printed 5 times with pauses in between each print. It works as expected in sync mode, but with async, I am having issues:
1) When run as a Java application , the following exception is thrown:
*
*
*org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [org.jbpm.pvm.internal.model.ExecutionImpl#7]*
2) When run as a unit test, each node only prints its name once, and the test passes.
I know that someone else posted the same error message (See http://community.jboss.org/message/525042#525042 http://community.jboss.org/message/525042#525042) and said that theirs worked as a unit test, and the conclusion was just to wait for 4.4. However, I really don't have much time! Can anyone verify whether 4.4 will fix this issue and when is the expected release date, or let me know what I'm doing wrong, or give me advice for a workaround?
Please help!
Thanks,
Rachel
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/535039#535039]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 7 months