Skip to content

External cache in redis for APQ and query planning#2024

Merged
Geal merged 30 commits intodevfrom
garypen/redis-experiment
Nov 9, 2022
Merged

External cache in redis for APQ and query planning#2024
Geal merged 30 commits intodevfrom
garypen/redis-experiment

Conversation

@Geal
Copy link
Contributor

@Geal Geal commented Oct 28, 2022

implement caching in external storage for query plans, introspection and APQ. This is done as a multi level cache, first in memory with LRU then with a redis cluster backend. Since it is still experimental, it is opt-in through a Cargo feature

@github-actions

This comment has been minimized.

@Geal Geal mentioned this pull request Nov 3, 2022
4 tasks
use serde::Serialize;
use tokio::sync::Mutex;

pub(crate) trait KeyType:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not seen this pattern before, nice :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found that was cool too :)

@BrynCooke
Copy link
Contributor

In general this seems like a good first step, and as per the comments there'll be some changes as we add more storage options later.

@Geal Geal marked this pull request as ready for review November 4, 2022 13:51
@Geal
Copy link
Contributor Author

Geal commented Nov 7, 2022

I think it's in a good shape now. Do we think things are missing to get it merged? What could be added after the merge (right now I'm thinking automatic reconnection to redis)

@BrynCooke
Copy link
Contributor

Let's go for merge

@Geal Geal enabled auto-merge (squash) November 9, 2022 13:21
@Geal Geal merged commit 44a5ede into dev Nov 9, 2022
@Geal Geal deleted the garypen/redis-experiment branch November 9, 2022 13:39
@abernix abernix added this to the v1-NEXT milestone Nov 15, 2022
@abernix abernix mentioned this pull request Nov 15, 2022
@Geal Geal changed the title redis experiment External cache in redis for APQ and query planning Nov 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants