Hi,<br>Can some one help in resolving the below issue or if there is any work around for this?<br><br>There is a strange behaviour in terms of loading the facts using dialect<br>java and mvel.<br>Our requirement is that we should support dynamic changes to fact objects in<br>
the application without a restart. So, to achieve that I am using jar<br>classloader to load the fact objects into memory. So before constructing<br>RuleBase I am switching the current class loader context to jar classloader.<br>
By doing this, all the imported facts getting resolved if I use mvel dialect<br>where as if I use java dialect it&#39;s not able to resolve the fact. Can<br>someone help on how to resolve this issue.<br>I can&#39;t use mvel dialect as it&#39;s behaving strangely in case of accumulate.<br>
So I need to use java dialect only.<br>Please let me know why java dialect is considering the facts only from<br>classpath. It&#39;s not loading from current classloader&#39;s context<br><br>Below is the code to switch classloader context<br>
Thread.currentThread().setContextClassLoader(<br>jarClassLoader);<br><br>InputStream is = //reads from jar content<br>RuleBase ruleBase = RuleBaseLoader.getInstance().loadFromReader(<br>                               new InputStreamReader(is));<br>
StatelessSession statelessSession = ruleBase.newStatelessSession();<br>statelessSession.executeWithResults(facts);<br><br><br>Thanks<br>Santhosh<br>