[jboss-user] [jBPM] - Re: WorkflowProcessInstanceUpgrader throwing ClassCastException: ...CommandBasedStatefulKnowledgeSession cannot be cast to ...InternalKnowledgeRuntime
Maciej Swiderski
do-not-reply at jboss.com
Fri Jan 11 10:20:13 EST 2013
Maciej Swiderski [https://community.jboss.org/people/swiderski.maciej] created the discussion
"Re: WorkflowProcessInstanceUpgrader throwing ClassCastException: ...CommandBasedStatefulKnowledgeSession cannot be cast to ...InternalKnowledgeRuntime"
To view the discussion, visit: https://community.jboss.org/message/790444#790444
--------------------------------------------------------------
Marcelo, maybe you could try something like this instead of all this casts:
StatefulKnowledgeSession ks = ksession.execute(new GenericCommand<StatefulKnowledgeSession>() {
public StatefulKnowledgeSession execute(Context context) {
return ((KnowledgeCommandContext) context).getStatefulKnowledgesession();
}
});
where ksession is CommandBasedStatefulKnowledgeSession and ks will be its undelying InternalKnowledgeRuntime.
HTH
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/790444#790444]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20130111/25c35902/attachment-0001.html
More information about the jboss-user
mailing list