Skip to content

Commit 2f16cdf

Browse files
authored
feat(cubestore): Support eviction for cache (#7034)
1 parent 2a0769f commit 2f16cdf

File tree

15 files changed

+2075
-101
lines changed

15 files changed

+2075
-101
lines changed

rust/cubestore/Cargo.lock

Lines changed: 18 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rust/cubestore/cubestore/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ csv = "1.1.3"
3434
bytes = "0.5.4"
3535
serde_json = "1.0.56"
3636
futures = "0.3.26"
37-
smallvec = "1.8.0"
37+
smallvec = "1.11.0"
3838
flexbuffers = "0.1.1"
3939
byteorder = "1.3.4"
4040
log = "=0.4.11"
@@ -53,7 +53,7 @@ chrono-tz = "0.8.2"
5353
lazy_static = "1.4.0"
5454
mockall = "0.8.1"
5555
async-std = "0.99"
56-
itertools = "0.9.0"
56+
itertools = "0.11.0"
5757
bigdecimal = { version = "0.2.0", features = ["serde"] }
5858
rust-s3 = "0.26.3"
5959
aws-creds = "0.24.1"

rust/cubestore/cubestore/src/app_metrics.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ pub static CACHE_QUERY_TIME_MS: Histogram = metrics::histogram("cs.sql.query.cac
2424
/// Incoming queue queries.
2525
pub static QUEUE_QUERIES: Counter = metrics::counter("cs.sql.query.queue");
2626
pub static QUEUE_QUERY_TIME_MS: Histogram = metrics::histogram("cs.sql.query.queue.ms");
27-
2827
pub static STREAMING_ROWS_READ: Counter = metrics::counter("cs.streaming.rows");
2928
pub static STREAMING_CHUNKS_READ: Counter = metrics::counter("cs.streaming.chunks");
3029
pub static STREAMING_LASTOFFSET: Gauge = metrics::gauge("cs.streaming.lastoffset");
@@ -68,3 +67,12 @@ pub static REMOTE_FS_OPERATION_CORE: Counter = metrics::counter("cs.remote_fs.op
6867
pub static REMOTE_FS_FILES_TO_REMOVE: Gauge = metrics::gauge("cs.remote_fs.files_to_remove.count");
6968
pub static REMOTE_FS_FILES_SIZE_TO_REMOVE: Gauge =
7069
metrics::gauge("cs.remote_fs.files_to_remove.size");
70+
71+
/// Cache Store Cache
72+
pub static CACHESTORE_TTL_PERSIST: Counter = metrics::counter("cs.cachestore.ttl.persist");
73+
pub static CACHESTORE_TTL_BUFFER: Gauge = metrics::gauge("cs.cachestore.ttl.buffer");
74+
// Cache Store Eviction
75+
pub static CACHESTORE_EVICTION_REMOVED_KEYS: Counter =
76+
metrics::counter("cs.cachestore.eviction.removed.keys");
77+
pub static CACHESTORE_EVICTION_REMOVED_SIZE: Counter =
78+
metrics::counter("cs.cachestore.eviction.removed.size");

0 commit comments

Comments
 (0)