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

CCE when storing a session with activations in its agenda

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

    XMLWordPrintable

Details

    • Hide

      Download the code in test.tar.gz
      run "tar -vzxf test.tar.gz && cd test && mvn clean install"
      see test/target/surefire-reports/ar.com.marianbuenosayres.test.MyTest.txt to see stack trace

      Show
      Download the code in test.tar.gz run "tar -vzxf test.tar.gz && cd test && mvn clean install" see test/target/surefire-reports/ar.com.marianbuenosayres.test.MyTest.txt to see stack trace

    Description

      When trying to persist (serialize) a session that has an activated agenda, a ClassCastException occurs like this when calling fireAllRules():

      java.lang.RuntimeException: Unable to commit transaction
      at org.drools.persistence.jta.JtaTransactionManager.commit(JtaTransactionManager.java:182)
      at org.drools.persistence.SingleSessionCommandService.execute(SingleSessionCommandService.java:376)
      at org.drools.command.impl.CommandBasedStatefulKnowledgeSession.fireAllRules(CommandBasedStatefulKnowledgeSession.java:245)
      ...
      Caused by: java.lang.ClassCastException: java.lang.Boolean cannot be cast to org.drools.spi.Activation
      at org.drools.common.ActivationIterator.next(ActivationIterator.java:59)
      at org.drools.marshalling.impl.ProtobufOutputMarshaller.writeAgenda(ProtobufOutputMarshaller.java:237)
      at org.drools.marshalling.impl.ProtobufOutputMarshaller.serializeSession(ProtobufOutputMarshaller.java:132)
      at org.drools.marshalling.impl.ProtobufOutputMarshaller.writeSession(ProtobufOutputMarshaller.java:100)
      at org.drools.marshalling.impl.ProtobufMarshaller.marshall(ProtobufMarshaller.java:169)
      at org.drools.marshalling.impl.ProtobufMarshaller.marshall(ProtobufMarshaller.java:151)

      I'll attach a project that reproduces this error on the next comment

      Attachments

        Activity

          People

            mfusco@redhat.com Mario Fusco
            marianbuenosayres Mariano Nicolas De Maio (Inactive)
            Archiver:
            rhn-support-ceverson Clark Everson

            Dates

              Created:
              Updated:
              Resolved:
              Archived:

              PagerDuty