[jboss-user] [jBPM] - Re: KnowledgeBase loading on demand

Maciej Swiderski do-not-reply at jboss.com
Thu Jul 5 08:35:43 EDT 2012

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

"Re: KnowledgeBase loading on demand"

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

Then you could manually operate on the knowledge base, something like this:

      KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();
     // add you process definitions here...
     kbuilder.add(ResourceFactory.newFileResource(subfile), ResourceType.BPMN2);
     // if you like to remove it you can remove the package

So you can load the process definitions from whatever source you want, if not already supported by ResourceFactory you can implement your own...

Please nore that building knowledge base is considered a heavy operation and should be rather reused instead of rebuilt frequently.


Reply to this message by going to Community

Start a new discussion in jBPM at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120705/47f4ada5/attachment.html 

More information about the jboss-user mailing list