Skip to content

Ask the HotKV docs

Answers come only from these docs and can be wrong; check the linked pages before you rely on them.

LATENCY HISTORY

Last updated
LATENCY HISTORY event
Group
Server
Complexity
O(N) where N is the number of spikes recorded for the event
Arity
3 (exactly, counting the command name)
HotKV Cloud
All plans
On-Premise
no license needed

LATENCY HISTORY returns the spikes recorded for one event, oldest first. Each event keeps its most recent 160 spikes. The event name is case-sensitive: use it exactly as LATENCY LATEST shows it.

An array of [unix-time, milliseconds] pairs (two integers each), in RESP2 and RESP3. An event with no spikes, or an unknown name, gives an empty array. Any number of arguments other than one event gets ERR wrong number of arguments for 'latency|history' command.

127.0.0.1:6379> LATENCY HISTORY command
1) 1) (integer) 1789999800
2) (integer) 75
2) 1) (integer) 1790000000
2) (integer) 120

Same reply shape as Redis 7 and Valkey 8.

LATENCY GRAPH, LATENCY LATEST