[infinispan-issues] [JBoss JIRA] (ISPN-4654) AND over range queries does not work (indexless query)

Adrian Nistor (JIRA) issues at jboss.org
Wed Aug 20 13:03:30 EDT 2014


    [ https://issues.jboss.org/browse/ISPN-4654?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12994453#comment-12994453 ] 

Adrian Nistor commented on ISPN-4654:
-------------------------------------

The assert should actually be {quote}assertEquals(3, list.size());{quote}, otherwise the test is fine for non-indexed and it correctly demonstrates the problem. 

Unfortunately this test should pass in the Lucene case, but surprisingly it does not. But this happens for different reasons than in non-indexed case: 1. 'id' field is not @NumericField, 2. 'age' is nullable, which basically cancels the fact it is a numeric field (because nullable fields are actually represented as strings - Lucene weirdness...). So the comparisons happen on strings and the end result is incorrect.

I'll fix the non-indexed case ASAP, but the Lucene case needs to be addressed separately.

> AND over range queries does not work (indexless query)
> ------------------------------------------------------
>
>                 Key: ISPN-4654
>                 URL: https://issues.jboss.org/browse/ISPN-4654
>             Project: Infinispan
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: Embedded Querying, Remote Querying
>    Affects Versions: 6.0.2.Final, 7.0.0.Beta1
>            Reporter: Radim Vansa
>            Assignee: Adrian Nistor
>
> Check this in QueryDslConditionsTest:
> {code}
>    public void testAnd5() throws Exception {
>       QueryFactory qf = getQueryFactory();
>       // range queries use different code
>       Query q = qf.from(getModelFactory().getUserImplClass())
>             .having("id").lt(1000)
>             .and().having("age").lt(1000)
>             .toBuilder().build();
>       List<User> list = q.list();
>       assertEquals(3, list.size());
>    }
> {code}
> The problem is that some subscription gets suspended and the second LT does not fire the second predicate update (and then neither the AND reevaluation).



--
This message was sent by Atlassian JIRA
(v6.2.6#6264)


More information about the infinispan-issues mailing list