[jboss-jira] [JBoss JIRA] (DROOLS-2542) KieHelper.getKieContainer() is not thread-safe

Edson Tirelli (JIRA) issues at jboss.org
Tue May 15 21:04:00 EDT 2018


     [ https://issues.jboss.org/browse/DROOLS-2542?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Edson Tirelli reassigned DROOLS-2542:
-------------------------------------

    Assignee: Mario Fusco  (was: Edson Tirelli)


> KieHelper.getKieContainer() is not thread-safe
> ----------------------------------------------
>
>                 Key: DROOLS-2542
>                 URL: https://issues.jboss.org/browse/DROOLS-2542
>             Project: Drools
>          Issue Type: Bug
>    Affects Versions: 7.7.0.Final
>            Reporter: Nils Meyer
>            Assignee: Mario Fusco
>
> Calling org.kie.api.KieServices.newKieContainer(ReleaseId, ClassLoader), in the way it is done in org.kie.internal.utils.KieHelper.getKieContainer() can cause problems in situations where concurrent threads are in action. newKieContainer reads the latest KieModule from the repository that was written by a builder. If multiple builders for different rules are running in parallel, it's not predictable, which rules will be used when creating a new session (see my sample below).
> I'm aware that I can work around this issue by using ReleaseIds, but nevertheless this behavior is cumbersome if you'd like to understand the relation between the KieFileSystem and the KieContainer in org.kie.internal.utils.KieHelper.getKieContainer() 



--
This message was sent by Atlassian JIRA
(v7.5.0#75005)


More information about the jboss-jira mailing list