I need to move the data from a relation database into a Redis store for further manipulations. I'm using the Symfony PSR-16 cache implementation with the Redis adapter for this and have 2 types of items in my cache pool:
- The first cache item type maps some hash onto the primary key of a record from the relational database, the item key looks like
hash.[the hash value]
and the item's value is the primary key accordingly. - The second cache item type has the key like
[table name].[primary key]
Now I need to loop through the items of the first type, take the the primary keys from them and fetch the items of the second type using these PKs.
Is it at all possible with the Symfony cache or I need to make some service working with Redis directly for a more flexible approach?
Is it possible to fetch Symfony cache items using regular expressions or tags?