2 Replies Latest reply: Aug 12, 2013 7:50 AM by Smita K RSS

Drools Guvnor 5.0.1 - Memory Usage Tuning

Themistoklis Dakanalis Newbie

Hi,

 

We're using Drools Guvnor 5.0.1 in a production environment, running on Tomcat 6.  We're experiencing permgen issues, particularly when doing large imports of rules, archiving, or compilation of rules.

 

Following permgen exceptions, we increased the permgen to :

-XX:MaxPermSize=2048M -ms3192M -mx3192M.

 

This sustained us for a while, but our assets are ever growing, and again we're exceeding the permgen space allocated.  Can someone recommend appropriate settings/configuration in order to reduce the memory/cpu usage?

 

Assets in Guvnor:

~ 21K rules in 11 decision tables (.xls) in 1 package

 

Thanks,

Themistoklis Dakanalis

  • 1. Re: Drools Guvnor 5.0.1 - Memory Usage Tuning
    Themistoklis Dakanalis Newbie

    Hi again,

     

    I have collect some more information regarding the problem I mentioned in my previous post. I take a thread dump during the compilation process and as I can see the thread that makes the compilation is the following:

     

    "http-8080-20" daemon prio=10 tid=0x00007f445054d800 nid=0x6abb runnable [0x00007f444db7f000]

       java.lang.Thread.State: RUNNABLE

            at org.eclipse.jdt.core.compiler.

    CharOperation.equals(CharOperation.java:1641)
            at org.eclipse.jdt.internal.compiler.util.HashtableOfPackage.put(HashtableOfPackage.java:69)
            at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.addNotFoundPackage(PackageBinding.java:45)
            at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getPackage(PackageBinding.java:102)
            at org.eclipse.jdt.internal.compiler.lookup.CompilationUnitScope.buildTypeBindings(CompilationUnitScope.java:119)
            at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.buildTypeBindings(LookupEnvironment.java:147)
            at org.eclipse.jdt.internal.compiler.Compiler.internalBeginToCompile(Compiler.java:701)
            at org.eclipse.jdt.internal.compiler.Compiler.beginToCompile(Compiler.java:376)
            at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:420)
            at org.drools.commons.jci.compilers.EclipseJavaCompiler.compile(EclipseJavaCompiler.java:351)
            at org.drools.commons.jci.compilers.AbstractJavaCompiler.compile(AbstractJavaCompiler.java:51)
            at org.drools.rule.builder.dialect.java.JavaDialect.compileAll(JavaDialect.java:389)
            at org.drools.compiler.DialectCompiletimeRegistry.compileAll(DialectCompiletimeRegistry.java:56)
            at org.drools.compiler.PackageRegistry.compileAll(PackageRegistry.java:74)
            at org.drools.compiler.PackageBuilder.compileAll(PackageBuilder.java:690)
            at org.drools.compiler.PackageBuilder.addPackage(PackageBuilder.java:653)
            at org.drools.compiler.PackageBuilder.addPackageFromDrl(PackageBuilder.java:278)
            at org.drools.guvnor.server.contenthandler.DecisionTableXLSHandler.compile(DecisionTableXLSHandler.java:64)

     

    Supposing that there is not any way to reduce the memory/cpu usage and the time delay (1 hour for the compilation of 22K rules) of the compilation process, is there any way to reduce the priority of the above thread, so that the other threads will not be stacked, and to restore the priority after the end of the compilation process?  

     

    Is this the appropriate forum to ask such kind of questions? If not where can I find some answers?

     

    Thanks in advance, 

    Themistoklis Dakanalis

  • 2. Re: Drools Guvnor 5.0.1 - Memory Usage Tuning
    Smita K Newbie

    Hi, did you find any solution to above problem? we are facing the same issue now. we are deploying Guvnor using apache-tomcat-7.0.16. It will be great if you could provide the solution.