Search code examples
cachingh2ignite

Apache ignite QueryEntity Based Configuration


My model (i.e. valueType) is wrapped Map -

class Model { 
  Map<String,Object> data; 
  Object  get(String key){} 
} 

How to get all "Models" ordered by data's some keys.

I want to execute this query on Models cache "select * from Model ORDER BY name* " where the "name" is some key of the "data". How can I do that my "indexes" to be my "data" 's some keys.


Solution

  • You can't index collection elements. Instead, you should have name as a separate field and configure it to be indexed in corresponding QueryEntity.