mirror of
https://github.com/fluencelabs/redis
synced 2025-06-15 10:11:21 +00:00
Extend REDISMODULE_CTX_FLAGS to indicate if redis is currently loading from either RDB or AOF
This commit is contained in:
@ -1455,6 +1455,9 @@ int RM_GetContextFlags(RedisModuleCtx *ctx) {
|
||||
if (server.cluster_enabled)
|
||||
flags |= REDISMODULE_CTX_FLAGS_CLUSTER;
|
||||
|
||||
if (server.loading)
|
||||
flags |= REDISMODULE_CTX_FLAGS_LOADING;
|
||||
|
||||
/* Maxmemory and eviction policy */
|
||||
if (server.maxmemory > 0) {
|
||||
flags |= REDISMODULE_CTX_FLAGS_MAXMEMORY;
|
||||
|
Reference in New Issue
Block a user