Added config flags max-memory and eviction-policy to manage memory usage. Created ParseMemory utility function to parse max-memory value into bytes. Created LFU cache to be used with heap data structure for managing LFU cache.

This commit is contained in:
Kelvin Clement Mwinuka
2024-03-01 16:25:04 +08:00
parent 97b41da729
commit e569bf6837
30 changed files with 364 additions and 228 deletions

View File

@@ -32,6 +32,7 @@ CMD "./server" \
"--restore-snapshot=${RESTORE_SNAPSHOT}" \
"--restore-aof=${RESTORE_AOF}" \
"--aof-sync-strategy=${AOF_SYNC_STRATEGY}" \
"--max-memory=${MAX_MEMORY}" \
# List of server cert/key pairs
"--cert-key-pair=${CERT_KEY_PAIR_1}" \
"--cert-key-pair=${CERT_KEY_PAIR_2}" \