Package redis.clients.jedis.commands
Interface ClientBinaryCommands
- All Known Subinterfaces:
ControlBinaryCommands
- All Known Implementing Classes:
Jedis
public interface ClientBinaryCommands
The interface contain all the commands about client.
The params is byte[]
-
Method Summary
Modifier and TypeMethodDescriptionbyte[]Returns the name of the current connection as set by CLIENT SETNAMElongclientId()Returns the ID of the current connection.byte[]Returns information and statistics about the current client connection in a mostly human readable format.clientKill(byte[] ipPort) Close a given client connection.clientKill(String ip, int port) Close a given client connection.longclientKill(ClientKillParams params) Close a given client connection.byte[]Returns information and statistics about the client connections server in a mostly human readable format.byte[]clientListBinary(long... clientIds) Returns information and statistics about the client connections server in a mostly human readable format filter by client ids.byte[]clientListBinary(ClientType type) Returns information and statistics about the client connections server in a mostly human readable format filter by client type.Turn off the client eviction mode for the current connection.Turn on the client eviction mode for the current connection.clientPause(long timeout) A connections control command able to suspend all the Redis clients for the specified amount of time (in milliseconds)clientPause(long timeout, ClientPauseMode mode) A connections control command able to suspend all the Redis clients for the specified amount of time (in milliseconds)clientSetInfo(ClientAttributeOption attr, byte[] value) client set info command Since redis 7.2clientSetname(byte[] name) Assigns a name to the current connection.longclientUnblock(long clientId) Unblock from a different connection, a client blocked in a blocking operation, such as for instance BRPOP or XREAD or WAIT.longclientUnblock(long clientId, UnblockType unblockType) Unblock from a different connection, a client blocked in a blocking operation, such as for instance BRPOP or XREAD or WAIT.CLIENT UNPAUSE is used to resume command processing for all clients that were paused by CLIENT PAUSE.
-
Method Details
-
clientKill
Close a given client connection.- Parameters:
ipPort- The ip:port should match a line returned by the CLIENT LIST command (addr field).- Returns:
- close success return OK
-
clientKill
Close a given client connection.- Parameters:
ip- The ip should match a line returned by the CLIENT LIST command (addr field).port- The port should match a line returned by the CLIENT LIST command (addr field).- Returns:
- Close success return OK
-
clientKill
Close a given client connection.- Parameters:
params- connect info will be closed- Returns:
- Close success return OK
-
clientGetnameBinary
byte[] clientGetnameBinary()Returns the name of the current connection as set by CLIENT SETNAME- Returns:
- Current connect name
-
clientListBinary
byte[] clientListBinary()Returns information and statistics about the client connections server in a mostly human readable format.- Returns:
- All clients info connected to redis-server
-
clientListBinary
Returns information and statistics about the client connections server in a mostly human readable format filter by client type.- Returns:
- all clients info connected to redis-server
-
clientListBinary
byte[] clientListBinary(long... clientIds) Returns information and statistics about the client connections server in a mostly human readable format filter by client ids.- Parameters:
clientIds- Unique 64-bit client IDs- Returns:
- All clients info connected to redis-server
-
clientInfoBinary
byte[] clientInfoBinary()Returns information and statistics about the current client connection in a mostly human readable format.- Returns:
- Information and statistics about the current client connection
-
clientSetInfo
client set info command Since redis 7.2- Parameters:
attr- the attr optionvalue- the value- Returns:
- OK or error
-
clientSetname
Assigns a name to the current connection.- Parameters:
name- Current connection name- Returns:
- OK if the connection name was successfully set.
-
clientId
long clientId()Returns the ID of the current connection.- Returns:
- The id of the client.
-
clientUnblock
long clientUnblock(long clientId) Unblock from a different connection, a client blocked in a blocking operation, such as for instance BRPOP or XREAD or WAIT.- Parameters:
clientId- The id of the client- Returns:
- Specifically: 1 if the client was unblocked successfully. 0 if the client wasn't unblocked.
-
clientUnblock
Unblock from a different connection, a client blocked in a blocking operation, such as for instance BRPOP or XREAD or WAIT.- Parameters:
clientId- The id of the clientunblockType- TIMEOUT|ERROR- Returns:
- Specifically: 1 if the client was unblocked successfully. 0 if the client wasn't unblocked.
-
clientPause
A connections control command able to suspend all the Redis clients for the specified amount of time (in milliseconds)- Parameters:
timeout- WRITE|ALL- Returns:
- The command returns OK or an error if the timeout is invalid.
-
clientPause
A connections control command able to suspend all the Redis clients for the specified amount of time (in milliseconds)- Parameters:
timeout- Command timeoutmode- WRITE|ALL- Returns:
- The command returns OK or an error if the timeout is invalid.
-
clientUnpause
String clientUnpause()CLIENT UNPAUSE is used to resume command processing for all clients that were paused by CLIENT PAUSE.- Returns:
- OK
-
clientNoEvictOn
String clientNoEvictOn()Turn on the client eviction mode for the current connection.- Returns:
- OK
-
clientNoEvictOff
String clientNoEvictOff()Turn off the client eviction mode for the current connection.- Returns:
- OK
-