[infinispan-dev] Search keys by query

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[infinispan-dev] Search keys by query

Sergey Chernolyas
Hi!
I want ask about search keys. For example, I have a complex key and the complex key (POJO) have a field “type”.  It is logical if I find all keys with required type by query. Now query for complex keys not work. Method “list()” return empty list(). Is the feature implementable?

--
---------------------

With best regards, Sergey Chernolyas

_______________________________________________
infinispan-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/infinispan-dev
Reply | Threaded
Open this post in threaded view
|

Re: [infinispan-dev] Search keys by query

Adrian Nistor
Hi Sergey,
keys are just keys. Lookup by key works only if you know the key in advance, be it a simple or complex key.
Keys are not indexed. So no, searching for keys does not work and there is no plan to support that. It's one of the many things Infinispan cannot do because it is not a relational database and we do no plan to become one :).
But there are ways to overcome this limitation. You already de-normalize your data when placing it in the grid, because Infinispan does not manage relations. During this process you should copy relevant properties of the key into the value itself if you intend to search by those properties.

Adrian

On 04/23/2018 11:26 AM, Sergey Chernolyas wrote:
Hi!
I want ask about search keys. For example, I have a complex key and the complex key (POJO) have a field “type”.  It is logical if I find all keys with required type by query. Now query for complex keys not work. Method “list()” return empty list(). Is the feature implementable?

--
---------------------

With best regards, Sergey Chernolyas


_______________________________________________
infinispan-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/infinispan-dev



_______________________________________________
infinispan-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/infinispan-dev