We are using Lettuce java client to connect to AWS Elasticache (Valkey engine, Serverless, version 8.0) from Java springboot application (JDK 17 & springboot version 3.2.5)
We have User information stored in cache with userId as cache key & the whole user object (in JSON format) as cache value. Example key value given below.
key = user:100
value =
{
"userId": 100,
"firstName": "James",
"lastName": "Paul",
"mobile": 5349997236
}
We can read from cache using jsonGet() by providing cache key. But I want to read from cache using other fields like, I want to retrieve all the users who have firstName = "James" WITHOUT providing cache key.
Is this possible to filter cache values using internal json fields instead of cache key?