Hide Forgot
Title: Searching Describe the issue: "Wrap the query in a org.hibernate.Query to get the required functionality from the Query API." >>> there's no org.hibernate.Query in JDG it should be "org.infinispan.query.CacheQuery" The example is wrong as it's using Hibernate API. Suggestions for improvement: This is the correct example code: // create native Lucene query unsing the query DSL // alternatively you can write the Lucene query using the Lucene query parser // or the Lucene programmatic API. The Infinispan Query DSL is recommended QueryBuilder qb = Search.getSearchManager(cache).buildQueryBuilderForClass(Book.class).get(); org.apache.lucene.search.Query query = qb .keyword() .onFields("title", "author") .matching("Java rocks!") .createQuery(); // wrap Lucene query in a org.infinispan.query.CacheQuery CacheQuery cacheQuery = Search.getSearchManager(cache).getQuery(query); List list = cacheQuery.list();
WIP
Removed JPA example. Corrected to org.infinispan.query.CacheQuery. Corrected code example as described above.
The fix for this bug is now generally released and available here: https://access.redhat.com/site/documentation/en-US/Red_Hat_JBoss_Data_Grid/6.2/index.html