Kris Verlaenen [
http://community.jboss.org/people/KrisVerlaenen] created the discussion
"Re: NullPointerException problem when console tried to start new sub process,
triggered by signal sent from async task"
To view the discussion, visit:
http://community.jboss.org/message/613357#613357
--------------------------------------------------------------
Hi,
It seems your FileCollector is directly accessing the internal session. Note however,
when using persistence, we actually wrap this internal session with a command service
(SingleSessionCommandService) that takes care of persistence etc. This seems to be an
issue where you're getting issues by directly accessing the internal session,
bypassing persistence setup etc.
You should not talk to the internal session directly, your client calls should always go
through the command service, using the ksession you get when using the JPAKnowledgeService
to construct the session.
Not sure if I understand your second issue. The engine typically uses the calling thread
to execute. So if you call signalEvent, that thread will be used to send the event and
execute the any process instance that is triggered because of this. But this thread will
return as soon as processing is done. So this is either immediate (when there is no-one
interested in the event) or after the process instance has reached a wait state (which
again is almost instantaneous, as anything that is not should be modeled as an async task
anyway).
Kris
--------------------------------------------------------------
Reply to this message by going to Community
[
http://community.jboss.org/message/613357#613357]
Start a new discussion in jBPM at Community
[
http://community.jboss.org/choose-container!input.jspa?contentType=1&...]