Hey Sanne and others, before I send a pull request, can you review my impl of ISPN-2296 at https://github.com/luksa/infinispan/compare/ISPN-2296. I'd like your input on this before implementing this on clustered queries.
Basically here's what I did: Extracted an interface (QueryResultLoader - any ideas for a better name?) from EntityLoader and introduced ProjectionLoader. This took care of projection of actual fields. For projecting the cache key, I introduced ProjectionConverter, which translates the fields passed to cacheQuery.projection(fields) into fields that hsearch can deal with (currently, only ispn.ProjectionConstants.KEY is replaced with hsearch.ProjectionConstants.ID). The converter is then also used to convert the actual values returned by hsearch (for cacheQuery.projection(ProjectionConstants.KEY), it converts the id returned by hsearch into the cache key). Just for completeness, besides introducing ispn.PC.KEY, I also added PC.VALUE, which is equivalent to hsearch.PC.THIS. Marko _______________________________________________ infinispan-dev mailing list [email protected] https://lists.jboss.org/mailman/listinfo/infinispan-dev
