1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-04 15:02:09 +03:00

CAE-193: add "IGNORE" options to time series commands (for v4 branch) (#2752)

This commit is contained in:
Shaya Potter
2024-07-10 19:45:33 +03:00
committed by GitHub
parent a1bee1caaf
commit 5576a0db49
7 changed files with 65 additions and 11 deletions

View File

@@ -127,6 +127,12 @@ export function transformTimestampArgument(timestamp: Timestamp): string {
).toString();
}
export function pushIgnoreArgument(args: RedisCommandArguments, ignore?: ADD.TsIgnoreOptions) {
if (ignore !== undefined) {
args.push('IGNORE', ignore.MAX_TIME_DIFF.toString(), ignore.MAX_VAL_DIFF.toString());
}
}
export function pushRetentionArgument(args: RedisCommandArguments, retention?: number): RedisCommandArguments {
if (retention !== undefined) {
args.push(