Skip to content

[Cache] create RedisTagAwareAdapter to reduce roundtrips #28250

@nicolas-grekas

Description

@nicolas-grekas

Thanks to Lua scripting capabilities of Redis, we should be able to implement the tag invalidation logic in Redis itself:

On data read, Redis would return the item if its tag versions are up to date. If not Redis would prune the item+its tags. The write + invalidation logic should remain basically the same. We could also implement PruneableInterface on this adapter.

I think this would make Redis the most efficient backend for tagged items.
A similar strategy could also work for a PdoTagAwareAdapter btw.

See https://redis.io/commands/eval

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy