Uploaded image for project: 'JBoss ESB'
  1. JBoss ESB
  2. JBESB-642

JBossRulesRouter does not dispose of WorkingMemory

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 4.2 Milestone Release 2
    • Fix Version/s: 4.2
    • Component/s: Content Based Routing
    • Labels:
      None

      Description

      In examining the JBossRulesRouter code it does not dispose of workingMemory (statefulSession) at the end of the method.

      WorkingMemory workingMemory = ruleBase.newStatefulSession();
      logger.log(Level.DEBUG,
      "Obtained message=" + message + " with ruleSet=" + ruleSet);
      workingMemory.setGlobal("destinations", destinations);
      if (objectList!=null) {
      for (Object object : objectList)

      { workingMemory.assertObject(object); }

      }
      workingMemory.assertObject(message);
      logger.log(Level.DEBUG, "Fire the JBossRules Engine");
      workingMemory.fireAllRules();
      logger.log(Level.DEBUG,
      "Outgoing Destinations: " + destinations);
      return destinations;
      }

      I believe it should:

      i.e.,

      WorkingMemory workingMemory = ruleBase.newStatefulSession();
      ...
      workingMemory.dispose();

      This allows garbage collection of the workingMemory.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                kurtstam Kurt Stam
                Reporter:
                jeffdelong Jeff DeLong
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: