- Usage:
-
CLIENT GETNAME
- Complexity:
- O(1)
- Since:
- 2.6.9
- ACL Categories:
- @connection, @slow
-
Bulk string reply: the connection name of the current connection.
-
Nil reply: the connection name was not set.
-
Bulk string reply: the connection name of the current connection.
-
Null reply: the connection name was not set.
The CLIENT GETNAME returns the name of the current connection as set by CLIENT SETNAME. Since every new connection starts without an associated name, if no name was assigned a null bulk reply is returned.
RESP2 Reply
One of the following:
RESP3 Reply
One of the following: