[jboss-user] [jBPM] - Re: Questions about knowledge session and memory resource issues

Maciej Swiderski do-not-reply at jboss.com
Thu May 10 02:01:52 EDT 2012


Maciej Swiderski [https://community.jboss.org/people/swiderski.maciej] created the discussion

"Re: Questions about knowledge session and memory resource issues"

To view the discussion, visit: https://community.jboss.org/message/734640#734640

--------------------------------------------------------------
> pmukundan wrote:
> 
> *Questions* 
> 1. Does JBPM keep all process instance information in memory at all times ?
Process instance is kept in session (working memory) one when it is active, meaning under execution. Once done with the processing it is persisted into db.

> pmukundan wrote:
> 
> *Questions* 
> 2. Does JBPM keep all the knowledge base in memory at all times ?
Yes, knowledge base is kept there all the time to secure all sessions will have access to all artifacts stored in it.

> pmukundan wrote:
> 
> 3. For approach b to work, the internal handling of JBPM should enable me to load/unload session at will. Does that work well? any firsthand experience ?
> 
As far as I can tell it works well. If you keep session small you should get quite good performance.


> pmukundan wrote:
> 
> 4. For approach b, if session dispose is called, do all process instances associated with that session go dormant ? In other words, if a session dispose is executed, are the process instances started by that session still in memory ?
Once the process instance execution is completed (by completed I mean that it reached a safe point like human task or catch events that makes process be in a sort of wait state) it is persisted into db and will now longer be active/managed object. It still resides in memory as object but it is disconnected from the session so it is safe to dispose the session.


> pmukundan wrote:
> 5. My JVM crashes or needs to be restarted. Would all process instance information be loaded into memory automatically or would that be done programatically ?
No, they won't be, as mentioned earlier process instances are persisted in db and retrieved only when requested. Just make sure you load knowledge base and session on startup and register all work item handlers that are required.

NOTE: all my comments assume session persistence is used.

HTH
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/734640#734640]

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/20120510/40a40f9c/attachment-0001.html 


More information about the jboss-user mailing list