Uploaded image for project: 'JBRULES'
  1. JBRULES
  2. JBRULES-1323

Add caching to the Objenesis instance and move instance to the RuleBase level

This issue belongs to an archived project. You can view it, but you can't modify it. Learn more

    XMLWordPrintable

Details

    • Patch
    • Resolution: Done
    • Critical
    • 4.0.4, 5.0.0.M1
    • 4.0.3
    • None
    • None

    Description

      After moving to the 4.0.3 version we are taked notice of application performance degradation in comarisopn with 4.0.2. Aftert application profiling we found that most time of page loading takes our permission resolving system based on drools. For each permission request application creates new statefull session (we use statefull because facts needs a possibility to be dynamical) and after asserting some facts issued fireAllRules. Further application profiling lead us to the Objenesis calls. The creation of Objenesis's instantiator is a very slow operation and the results of instantiators creating was cached only during the working memorry life cycle (which is very short in our app). So its seems reasonlibe to turn on Objenesis cache, and move Objenesis instance to the RuleBase level to avoid memory leaks. The attached patch working for me and after applying our app working up to ten times faster.

      Attachments

        Activity

          People

            Unassigned Unassigned
            lucker_jira Alexander Gavrilov (Inactive)
            Archiver:
            rhn-support-ceverson Clark Everson

            Dates

              Created:
              Updated:
              Resolved:
              Archived:

              PagerDuty