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

Wrong type declartion initialization causes an infinite loop when using property reactivity

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

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 6.0.0.Alpha1
    • None
    • None
    • None

    Description

      A drl like the following with DataSample being annotated as @PropertyReactive ends up in an infinite loop even if it shouldn't.

      rule 'Init'
      when
      $m: Model()
      then
      insert(new DataSample($m));
      end

      rule "Rule 1"
      when
      $m: Model()
      $d: DataSample(model == $m)
      then
      modify($d)

      { addValue(Parameter.PARAM_A, 10.0) }

      end

      rule "Rule 2"
      when
      $m: Model()
      $d: DataSample(model == $m, $v: values[Parameter.PARAM_A] > 9.0)
      then
      modify($d)

      { addMessage("Hello") }

      end

      rule "Data without messages"
      salience -100
      when
      $m: Model()
      $d: DataSample(model == $m, messaged == false)
      then
      end

      Attachments

        Activity

          People

            mfusco@redhat.com Mario Fusco
            mfusco@redhat.com Mario Fusco
            Archiver:
            rhn-support-ceverson Clark Everson

            Dates

              Created:
              Updated:
              Resolved:
              Archived:

              PagerDuty