Maciej Swiderski [
https://community.jboss.org/people/swiderski.maciej] created the
discussion
"Re: Process Session ID always 0 in database"
To view the discussion, visit:
https://community.jboss.org/message/787388#787388
--------------------------------------------------------------
there are two issue with the code you use:
1. you create session that is not persisted and thus process instances are not persisted
either and if you create session for every process instance this is probably the reason of
having process instance id 0
2. when using HornetQ task client and connecting clients in parallel meaning more than one
at the same time (that does not have to mean they will be active at the same time but
rather they are connected) you need to ensue that each client is uniquely identified
so for issue 1 you should use JPAKnowledgeService to create/load session and that will
ensure you processes are stored in db too. for issue 2 you use pass unique name each time
you create AsynHornetQHTWorkItemHandler.
HTH
--------------------------------------------------------------
Reply to this message by going to Community
[
https://community.jboss.org/message/787388#787388]
Start a new discussion in jBPM at Community
[
https://community.jboss.org/choose-container!input.jspa?contentType=1&...]