Package redis.clients.jedis.commands
Interface ControlCommands
- All Superinterfaces:
AccessControlLogCommands,ClientCommands
- All Known Implementing Classes:
Jedis
The interface about Redis management command
-
Method Summary
Modifier and TypeMethodDescriptionReports about different memory-related issues that the Redis server experiences, and advises about possible remedies.Attempts to purge dirty pages so these can be reclaimed by the allocator.Returns an Array reply about the memory usage of the server.memoryUsage(String key) Reports the number of bytes that a key and its value require to be stored in RAM.memoryUsage(String key, int samples) Reports the number of bytes that a key and its value require to be stored in RAM.objectEncoding(String key) Returns the internal encoding for the Redis object stored atkey.objectFreq(String key) Returns the logarithmic access frequency counter of a Redis object stored atkey.Returns the object subcommands and usages.objectIdletime(String key) Returns the time in seconds since the last access to the value stored atkey.objectRefcount(String key) Returns the reference count of the stored atkey.role()Provide information on the role of a Redis instance in the context of replication, by returning if the instance is currently a master, slave, or sentinel.Methods inherited from interface redis.clients.jedis.commands.AccessControlLogCommands
aclCat, aclCat, aclDelUser, aclDelUser, aclDryRun, aclDryRun, aclGenPass, aclGenPass, aclGetUser, aclList, aclLoad, aclLog, aclLog, aclLogReset, aclSave, aclSetUser, aclSetUser, aclUsers, aclWhoAmIMethods inherited from interface redis.clients.jedis.commands.ClientCommands
clientGetname, clientId, clientInfo, clientKill, clientKill, clientKill, clientList, clientList, clientList, clientNoEvictOff, clientNoEvictOn, clientNoTouchOff, clientNoTouchOn, clientPause, clientPause, clientSetInfo, clientSetname, clientUnblock, clientUnblock, clientUnpause
-
Method Details
-
role
Provide information on the role of a Redis instance in the context of replication, by returning if the instance is currently a master, slave, or sentinel. The command also returns additional information about the state of the replication (if the role is master or slave) or the list of monitored master names (if the role is sentinel).- Returns:
- The information on the role of a Redis instance
-
objectRefcount
Returns the reference count of the stored atkey.- Parameters:
key- The key in Redis server- Returns:
- The reference count of the stored at
key
-
objectEncoding
Returns the internal encoding for the Redis object stored atkey.See for details: OBJECT ENCODING key
- Parameters:
key- The key in Redis server- Returns:
- The number of references
-
objectIdletime
Returns the time in seconds since the last access to the value stored atkey. The command is only available when the maxmemory-policy configuration directive is not set to one of the LFU policies.- Parameters:
key- The key in Redis server- Returns:
- The idle time in seconds
-
objectHelp
Returns the object subcommands and usages.- Returns:
- object subcommands and usages
-
objectFreq
Returns the logarithmic access frequency counter of a Redis object stored atkey.The command is only available when the maxmemory-policy configuration directive is set to one of the LFU policies.
- Parameters:
key- The key in Redis server- Returns:
- The counter's value
-
memoryDoctor
String memoryDoctor()Reports about different memory-related issues that the Redis server experiences, and advises about possible remedies. -
memoryUsage
Reports the number of bytes that a key and its value require to be stored in RAM. The reported usage is the total of memory allocations for data and administrative overheads that a key its value require.See for details: MEMORY USAGE key
- Parameters:
key- The key in Redis server- Returns:
- The memory usage in bytes, or
nilwhen the key does not exist
-
memoryUsage
Reports the number of bytes that a key and its value require to be stored in RAM. The reported usage is the total of memory allocations for data and administrative overheads that a key its value require.See for details: MEMORY USAGE key SAMPLES count
- Parameters:
key- The key in Redis server- Returns:
- The memory usage in bytes, or
nilwhen the key does not exist
-
memoryPurge
String memoryPurge()Attempts to purge dirty pages so these can be reclaimed by the allocator.- Returns:
- OK
-
memoryStats
Returns an Array reply about the memory usage of the server.- Returns:
- nested list of memory usage metrics and their values
-