[JBoss JIRA] (ISPN-5692) Registering a remote event listener fails if cache is indexed, uses protobuf marshalling and includeInitialState=true
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/ISPN-5692?page=com.atlassian.jira.plugin.... ]
RH Bugzilla Integration commented on ISPN-5692:
-----------------------------------------------
Dave Stahl <dstahl(a)redhat.com> changed the Status of [bug 1238164|https://bugzilla.redhat.com/show_bug.cgi?id=1238164] from POST to MODIFIED
> Registering a remote event listener fails if cache is indexed, uses protobuf marshalling and includeInitialState=true
> ---------------------------------------------------------------------------------------------------------------------
>
> Key: ISPN-5692
> URL: https://issues.jboss.org/browse/ISPN-5692
> Project: Infinispan
> Issue Type: Bug
> Components: Remote Querying
> Affects Versions: 7.2.4.Final
> Reporter: Adrian Nistor
> Assignee: Adrian Nistor
> Fix For: 8.0.0.CR1, 8.0.0.Final, 7.2.5.Final
>
>
> {quote}
> org.infinispan.client.hotrod.exceptions.HotRodClientException:Request for messageId=7 returned server error (status=0x85): org.infinispan.remoting.RemoteException: ISPN000217: Received exception from RemoteListenerWithDslFilterTest-NodeC-8427, see cause for remote stack trace
> java.lang.ClassCastException: org.infinispan.query.remote.indexing.ProtobufValueWrapper cannot be cast to [B
> at org.infinispan.client.hotrod.impl.protocol.Codec20.checkForErrorsInResponseStatus(Codec20.java:336)
> at org.infinispan.client.hotrod.impl.protocol.Codec20.readPartialHeader(Codec20.java:126)
> at org.infinispan.client.hotrod.impl.protocol.Codec20.readHeaderOrEvent(Codec20.java:208)
> at org.infinispan.client.hotrod.impl.operations.AddClientListenerOperation.executeOperation(AddClientListenerOperation.java:92)
> at org.infinispan.client.hotrod.impl.operations.AddClientListenerOperation.executeOperation(AddClientListenerOperation.java:25)
> at org.infinispan.client.hotrod.impl.operations.RetryOnFailureOperation.execute(RetryOnFailureOperation.java:52)
> at org.infinispan.client.hotrod.impl.RemoteCacheImpl.addClientListener(RemoteCacheImpl.java:575)
> at org.infinispan.client.hotrod.event.ClientEvents.addClientQueryListener(ClientEvents.java:65)
> at org.infinispan.client.hotrod.event.RemoteListenerWithDslFilterTest.testEventFilter(RemoteListenerWithDslFilterTest.java:144)
> {quote}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 10 months
[JBoss JIRA] (ISPN-5706) Execution of a Hibrid Query returns incorrect results, when the filter condition fails(match() returns false) for at least some of the results returned by the lucene query execution, before reaching any other successful results(which satisfies the filter)
by Prashanth Reddy (JIRA)
[ https://issues.jboss.org/browse/ISPN-5706?page=com.atlassian.jira.plugin.... ]
Prashanth Reddy updated ISPN-5706:
----------------------------------
Priority: Critical (was: Major)
> Execution of a Hibrid Query returns incorrect results, when the filter condition fails(match() returns false) for at least some of the results returned by the lucene query execution, before reaching any other successful results(which satisfies the filter)
> ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: ISPN-5706
> URL: https://issues.jboss.org/browse/ISPN-5706
> Project: Infinispan
> Issue Type: Bug
> Components: Embedded Querying
> Affects Versions: 8.0.0.Beta3
> Reporter: Prashanth Reddy
> Assignee: Adrian Nistor
> Priority: Critical
> Attachments: HybridQuery.diff
>
>
> The hibrid query, mentioned below produces partial or zero results(depending on the data), upon execution.
> SELECT p.ID, p.NAME FROM com.testapp.Person p WHERE p.IS_ACTIVE=1 AND p.ID>1000 and p.ID<10000
> For the data,
> ID | NAME | CITY | IS_ACTIVE
> -------------------
> 2001 person1 city1 0
> 2002 person1 city1 1
> 2003 person1 city1 1
> 2004 person1 city1 0
> 2005 person1 city2 1
> 2006 person1 city2 1
> 2007 person1 city3 0
> 2008 person1 city3 1
> Indexed fields: ID, NAME, CITY
> Non-indexed fields: IS_ACTIVE
> Query execution returned 0 number of rows, whereas expected result count is 8.
> Root cause for the problem is very trivial, and the details are as follows,
> As we know, hibrid query execution involves,
> * Execution of lucene query that is constructed based on boole shannon expansion
> * Applying filter on the results obtained from above operation, in order to cover the conditions that deals with non-indexed fields
> In the second step, there is a mismatch between the representation of filter operation return status and the way end of the result list is detected at the outer layer.
> As per the current implementation, filter operation returns null, if the filter condition is not satisfied. But, the same is also used for determining whether there are any further results to be retrieved, which is causing the actual problem.
> Following changes can resolve the problem,
> file: infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java
> diff:
> Index: infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java
> ===================================================================
> --- infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java (revision -----)
> +++ infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java (working copy)
> @@ -70,12 +70,15 @@
>
> private void update() {
> if (!isReady) {
> - if (it.hasNext()) {
> - Object next = it.next();
> - nextResult = objectFilter.filter(next);
> - } else {
> - nextResult = null;
> - }
> + do {
> + if (it.hasNext()) {
> + Object next = it.next();
> + nextResult = objectFilter.filter(next);
> + } else {
> + nextResult = null;
> + break;
> + }
> + } while (nextResult == null);
> isReady = true;
> }
> }
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 10 months
[JBoss JIRA] (ISPN-5706) Execution of a Hibrid Query returns incorrect results, when the filter condition fails(match() returns false) for at least some of the results returned by the lucene query execution, before reaching any other successful results(which satisfies the filter)
by Gustavo Fernandes (JIRA)
[ https://issues.jboss.org/browse/ISPN-5706?page=com.atlassian.jira.plugin.... ]
Gustavo Fernandes reassigned ISPN-5706:
---------------------------------------
Assignee: Adrian Nistor
> Execution of a Hibrid Query returns incorrect results, when the filter condition fails(match() returns false) for at least some of the results returned by the lucene query execution, before reaching any other successful results(which satisfies the filter)
> ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: ISPN-5706
> URL: https://issues.jboss.org/browse/ISPN-5706
> Project: Infinispan
> Issue Type: Bug
> Components: Embedded Querying
> Affects Versions: 8.0.0.Beta3
> Reporter: Prashanth Reddy
> Assignee: Adrian Nistor
> Attachments: HybridQuery.diff
>
>
> The hibrid query, mentioned below produces partial or zero results(depending on the data), upon execution.
> SELECT p.ID, p.NAME FROM com.testapp.Person p WHERE p.IS_ACTIVE=1 AND p.ID>1000 and p.ID<10000
> For the data,
> ID | NAME | CITY | IS_ACTIVE
> -------------------
> 2001 person1 city1 0
> 2002 person1 city1 1
> 2003 person1 city1 1
> 2004 person1 city1 0
> 2005 person1 city2 1
> 2006 person1 city2 1
> 2007 person1 city3 0
> 2008 person1 city3 1
> Indexed fields: ID, NAME, CITY
> Non-indexed fields: IS_ACTIVE
> Query execution returned 0 number of rows, whereas expected result count is 8.
> Root cause for the problem is very trivial, and the details are as follows,
> As we know, hibrid query execution involves,
> * Execution of lucene query that is constructed based on boole shannon expansion
> * Applying filter on the results obtained from above operation, in order to cover the conditions that deals with non-indexed fields
> In the second step, there is a mismatch between the representation of filter operation return status and the way end of the result list is detected at the outer layer.
> As per the current implementation, filter operation returns null, if the filter condition is not satisfied. But, the same is also used for determining whether there are any further results to be retrieved, which is causing the actual problem.
> Following changes can resolve the problem,
> file: infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java
> diff:
> Index: infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java
> ===================================================================
> --- infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java (revision -----)
> +++ infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java (working copy)
> @@ -70,12 +70,15 @@
>
> private void update() {
> if (!isReady) {
> - if (it.hasNext()) {
> - Object next = it.next();
> - nextResult = objectFilter.filter(next);
> - } else {
> - nextResult = null;
> - }
> + do {
> + if (it.hasNext()) {
> + Object next = it.next();
> + nextResult = objectFilter.filter(next);
> + } else {
> + nextResult = null;
> + break;
> + }
> + } while (nextResult == null);
> isReady = true;
> }
> }
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 10 months
[JBoss JIRA] (ISPN-5706) Execution of a Hibrid Query returns incorrect results, when the filter condition fails(match() returns false) for at least some of the results returned by the lucene query execution, before reaching any other successful results(which satisfies the filter)
by Prashanth Reddy (JIRA)
Prashanth Reddy created ISPN-5706:
-------------------------------------
Summary: Execution of a Hibrid Query returns incorrect results, when the filter condition fails(match() returns false) for at least some of the results returned by the lucene query execution, before reaching any other successful results(which satisfies the filter)
Key: ISPN-5706
URL: https://issues.jboss.org/browse/ISPN-5706
Project: Infinispan
Issue Type: Bug
Components: Embedded Querying
Affects Versions: 8.0.0.Beta3
Reporter: Prashanth Reddy
Attachments: HybridQuery.diff
The hibrid query, mentioned below produces partial or zero results(depending on the data), upon execution.
SELECT p.ID, p.NAME FROM com.testapp.Person p WHERE p.IS_ACTIVE=1 AND p.ID>1000 and p.ID<10000
For the data,
ID | NAME | CITY | IS_ACTIVE
-------------------
2001 person1 city1 0
2002 person1 city1 1
2003 person1 city1 1
2004 person1 city1 0
2005 person1 city2 1
2006 person1 city2 1
2007 person1 city3 0
2008 person1 city3 1
Indexed fields: ID, NAME, CITY
Non-indexed fields: IS_ACTIVE
Query execution returned 0 number of rows, whereas expected result count is 8.
Root cause for the problem is very trivial, and the details are as follows,
As we know, hibrid query execution involves,
* Execution of lucene query that is constructed based on boole shannon expansion
* Applying filter on the results obtained from above operation, in order to cover the conditions that deals with non-indexed fields
In the second step, there is a mismatch between the representation of filter operation return status and the way end of the result list is detected at the outer layer.
As per the current implementation, filter operation returns null, if the filter condition is not satisfied. But, the same is also used for determining whether there are any further results to be retrieved, which is causing the actual problem.
Following changes can resolve the problem,
file: infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java
diff:
Index: infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java
===================================================================
--- infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java (revision -----)
+++ infinispan-8.0.0.Beta3/query/src/main/java/org/infinispan/query/dsl/embedded/impl/HybridQuery.java (working copy)
@@ -70,12 +70,15 @@
private void update() {
if (!isReady) {
- if (it.hasNext()) {
- Object next = it.next();
- nextResult = objectFilter.filter(next);
- } else {
- nextResult = null;
- }
+ do {
+ if (it.hasNext()) {
+ Object next = it.next();
+ nextResult = objectFilter.filter(next);
+ } else {
+ nextResult = null;
+ break;
+ }
+ } while (nextResult == null);
isReady = true;
}
}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 10 months
[JBoss JIRA] (ISPN-5704) Enhancements for Functional Map API
by Galder Zamarreño (JIRA)
Galder Zamarreño created ISPN-5704:
--------------------------------------
Summary: Enhancements for Functional Map API
Key: ISPN-5704
URL: https://issues.jboss.org/browse/ISPN-5704
Project: Infinispan
Issue Type: Enhancement
Reporter: Galder Zamarreño
Assignee: Galder Zamarreño
Fix For: 8.1.0.Final
List of enhancements that didn't make it into 8.0:
* Transaction support.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 10 months
[JBoss JIRA] (ISPN-5685) Filtering doesn't work with sum aggregation
by Gustavo Fernandes (JIRA)
[ https://issues.jboss.org/browse/ISPN-5685?page=com.atlassian.jira.plugin.... ]
Gustavo Fernandes updated ISPN-5685:
------------------------------------
Status: Resolved (was: Pull Request Sent)
Resolution: Done
> Filtering doesn't work with sum aggregation
> -------------------------------------------
>
> Key: ISPN-5685
> URL: https://issues.jboss.org/browse/ISPN-5685
> Project: Infinispan
> Issue Type: Bug
> Affects Versions: 8.0.0.Beta3
> Reporter: Jakub Markos
> Assignee: Adrian Nistor
> Fix For: 8.0.0.Final
>
>
> The following query
> {code}
> public void testGroupBy() {
> QueryFactory qf = getQueryFactory();
> Query q = qf.from(getModelFactory().getTransactionImplClass())
> .select(Expression.property("accountId"), Expression.sum("amount"))
> .groupBy("accountId")
> .having(Expression.sum("amount")).gt(3324)
> .toBuilder().build();
> }
> {code}
> in the context of QueryDslConditionsTest test class fails with:
> {code}
> java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.Double
> at java.lang.Double.compareTo(Double.java:49)
> at org.infinispan.objectfilter.impl.util.Interval.contains(Interval.java:92)
> at org.infinispan.objectfilter.impl.predicateindex.IntervalCondition.match(IntervalCondition.java:19)
> at org.infinispan.objectfilter.impl.predicateindex.IntervalCondition.match(IntervalCondition.java:9)
> at org.infinispan.objectfilter.impl.predicateindex.Predicate.match(Predicate.java:37)
> at org.infinispan.objectfilter.impl.predicateindex.Predicates.notifyMatchingSubscribers(Predicates.java:118)
> at org.infinispan.objectfilter.impl.predicateindex.AttributeNode.processValue(AttributeNode.java:112)
> at org.infinispan.objectfilter.impl.predicateindex.RowMatcherEvalContext.processAttributes(RowMatcherEvalContext.java:30)
> at org.infinispan.objectfilter.impl.predicateindex.MatcherEvalContext.process(MatcherEvalContext.java:120)
> at org.infinispan.objectfilter.impl.ObjectFilterImpl.filter(ObjectFilterImpl.java:73)
> at org.infinispan.query.dsl.embedded.impl.HybridQuery$1.update(HybridQuery.java:75)
> at org.infinispan.query.dsl.embedded.impl.HybridQuery$1.hasNext(HybridQuery.java:56)
> at org.infinispan.query.dsl.embedded.impl.BaseEmbeddedQuery.listInternal(BaseEmbeddedQuery.java:72)
> at org.infinispan.query.dsl.embedded.impl.BaseEmbeddedQuery.list(BaseEmbeddedQuery.java:63)
> at org.infinispan.query.dsl.embedded.QueryDslConditionsTest.testGroupBy(QueryDslConditionsTest.java:1811)
> ...
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 10 months