]
Sanne Grinovero commented on ISPN-2337:
---------------------------------------
We opted for API changes, discussed here:
Review API for Query result iterators
-------------------------------------
Key: ISPN-2337
URL:
https://issues.jboss.org/browse/ISPN-2337
Project: Infinispan
Issue Type: Bug
Components: Querying
Affects Versions: 5.2.0.Alpha4
Reporter: Marko Lukša
Assignee: Marko Lukša
Priority: Critical
Fix For: 5.2.0.CR1
I have found multiple problems with the iterators returned by CacheQueryImpl.
- using LazyIterator with fetchSize fails with ArrayIndexOutOfBoundsException
- calling previous() after next() doesn't return expected element
- calling nextIndex() on a new iterator should return 0, not 1 (the same also applies
when calling nextIndex() after calling first())
- if fetchSize is greater than 1, LazyIterator fills the whole buffer on every invocation
of .previous() (if fetchSize = 10, then _every_ invocation of previous() loads 10 results
from the cache)
- nextIndex() and previousIndex() throw NoSuchElementException, which violates the
contract of ListInterface
- next() and previous() throw ArrayIndexOutOfBoundsException when they should be throwing
NoSuchElementException
- ...
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: