[jboss-jira] [JBoss JIRA] Reopened: (JBRULES-1999) Improve performance/configuration options of ChainedProperties use in StatelessSession.execute calls
Mark Proctor (JIRA)
jira-events at lists.jboss.org
Thu May 14 23:08:59 EDT 2009
[ https://jira.jboss.org/jira/browse/JBRULES-1999?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mark Proctor reopened JBRULES-1999:
-----------------------------------
> Improve performance/configuration options of ChainedProperties use in StatelessSession.execute calls
> ----------------------------------------------------------------------------------------------------
>
> Key: JBRULES-1999
> URL: https://jira.jboss.org/jira/browse/JBRULES-1999
> Project: JBoss Drools
> Issue Type: Feature Request
> Security Level: Public(Everyone can see)
> Components: drools-core
> Affects Versions: 5.0.0.M5
> Environment: Windows XP, Java 1.5.x Drools 4.x and 5.x releases
> Reporter: Jeff Adams
> Assignee: Mark Proctor
> Fix For: 5.0.1.FINAL
>
>
> Profiling my use of drools using JProfiler, I am loading one RulesBase, and subsequently creating StatelessSessions to reuse by calling execute() multiple times.
> JProfiler reported that my second biggest hotspot when calling StatelessSession.execute() 25k times was:
> sun.misc.CompoundEnumeration.hasMoreElements 17,427 ms (18 %)
> 18.7% - 17,427 ms org.drools.util.ChainedProperties.loadProperties
> 18.7% - 17,427 ms org.drools.util.ChainedProperties.<init>
> 18.7% - 17,427 ms org.drools.util.ChainedProperties.<init>
> 18.7% - 17,427 ms org.drools.util.ChainedProperties.<init>
> 18.7% - 17,427 ms org.drools.SessionConfiguration.init
> 18.7% - 17,427 ms org.drools.SessionConfiguration.<init>
> 18.7% - 17,427 ms org.drools.reteoo.ReteooStatelessSession.newWorkingMemory
> 18.7% - 17,427 ms org.drools.reteoo.ReteooStatelessSession.execute
> following this trace shows that every time StatelessSession.execute is called a new instance of
> new ChainedProperties( "session.conf" ) is created on each newWorkingMemory...
> But at least in my case, I don't really need to do all the work that new instance creation of of new ChainedProperties( "session.conf" ) does on each call, especially on every call to ReteooStatelessSession.execute.
> I also didn't see an easy way of cleanly overriding this.
> I did a test of just using an alternate version of SessionConfiguration that reused a shared instance of ChainedProperties and this still worked and saved me a majority of my execution time using these StatelessSessions.execute calls.
> Should this use of ChainedProperties in StatelessSessions be optional, or at least their cardinality configurable?
> Thanks
> Jeff
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list