[jboss-jira] [JBoss JIRA] Updated: (JBRULES-573) EqualityAssertMapComparator does not work with JSR94 Fact Handles

Mark Proctor (JIRA) jira-events at lists.jboss.org
Wed Jul 4 21:41:51 EDT 2007


     [ http://jira.jboss.com/jira/browse/JBRULES-573?page=all ]

Mark Proctor updated JBRULES-573:
---------------------------------

    Fix Version/s:  4.0.0.MR4

assigning this to fixfor 4.0 M4, so I can see if its fixed or not.

> EqualityAssertMapComparator does not work with JSR94 Fact Handles
> -----------------------------------------------------------------
>
>                 Key: JBRULES-573
>                 URL: http://jira.jboss.com/jira/browse/JBRULES-573
>             Project: JBoss Rules
>          Issue Type: Feature Request
>      Security Level: Public(Everyone can see) 
>    Affects Versions: 3.0.5
>         Environment: java 1.5.0_09
>            Reporter: Juergen none
>         Assigned To: Mark Proctor
>             Fix For:  4.0.0.MR4
>
>
> Equal objects are asserted multiple times via jsr94 interface
> Using jsr94 interface to use drools stateful rule session
> Assert behaviour set to equality:
> PROPERTY_ASSERT_BEHAVIOR = RuleBaseConfiguration.WM_BEHAVIOR_EQUALITY
> fact handle factory creates org.drools.jsr94.rules.Jsr94FactHandle objects
> BUT:
> org.drools.common.EqualityAssertMapComparator::hashCodeOf()
> obj.getClass() == this.factHandleClass is false because
> this.factHandleClass is DefaultFactHandle and
> obj.getClass() is Jsr94FactHandle
> --> so instead of hashcode of object wrapped by handle, hashcode of facthandle object is used --> equal objects are asserted multiple times
> GUESS: either
> - obj.getClass() instanceof this.factHandleClass or
> - this.factHandleClass should be set to Jsr94FactHandle?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list