S Root [
http://community.jboss.org/people/sroot] created the discussion
"JBPM5 Content data problem"
To view the discussion, visit:
http://community.jboss.org/message/625599#625599
--------------------------------------------------------------
Hi all!
I was wondering if someone might be able to assist with this.
I have a process with a custom task and User Task,
I have Map and couple of Strings def
ined as process variables.
When the process goes to human task, and I retrieve
the Content for the Task via the TaskClient using Mina, I am unable to restore the Map. I
found the following in the HumanTaskExample and it is exactly what I was doing
Content content = getContentResponseHandler.getContent();
ByteArrayInputStream bis = new ByteArrayInputStream(content.getContent());
ObjectInputStream in;
in = newObjectInputStream(bis);
Object result = in.readObject();
in.close();
Map<?, ?> map = (Map<?, ?>) result;
The problem is that "result" at this point is seen as a java.lang.String. All of
my data is there when I print it out but I am unable to cast it back to a map. My process
variable Map is being set when I complete the previous workitem
Am I missing something here? Looking at the JBPM source and examples it seems like this
should work.
I'd appreciate all input, thanks.
-Scott.
--------------------------------------------------------------
Reply to this message by going to Community
[
http://community.jboss.org/message/625599#625599]
Start a new discussion in jBPM at Community
[
http://community.jboss.org/choose-container!input.jspa?contentType=1&...]