@upstash/redis 1.18.5-rc.0 → 1.18.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -81,6 +81,12 @@ data = await redis.spop('animals', 1)
81
81
  console.log(data)
82
82
  ```
83
83
 
84
+ ## Troubleshooting
85
+
86
+ We have a [dedicated page](https://docs.upstash.com/troubleshooting) for common
87
+ problems. If you can't find a solution, please
88
+ [open an issue](https://github.com/upstash/upstash-redis/issues/new).
89
+
84
90
  ## Docs
85
91
 
86
92
  See [the documentation](https://docs.upstash.com/features/javascriptsdk) for
@@ -0,0 +1,9 @@
1
+ import { Command } from "./command.js";
2
+ /**
3
+ * @see https://redis.io/commands/zdiffstore
4
+ */
5
+ export class ZDiffStoreCommand extends Command {
6
+ constructor(cmd, opts) {
7
+ super(["zdiffstore", ...cmd], opts);
8
+ }
9
+ }
@@ -2,6 +2,7 @@ import { AppendCommand, BitCountCommand, BitOpCommand, BitPosCommand, DBSizeComm
2
2
  import { UpstashError } from "./error.js";
3
3
  import { ZMScoreCommand } from "./commands/zmscore.js";
4
4
  import { HRandFieldCommand } from "./commands/hrandfield.js";
5
+ import { ZDiffStoreCommand } from "./commands/zdiffstore.js";
5
6
  /**
6
7
  * Upstash REST API supports command pipelining to send multiple commands in
7
8
  * batch, instead of sending each command one by one and waiting for a response.
@@ -133,6 +134,15 @@ export class Pipeline {
133
134
  writable: true,
134
135
  value: (...args) => this.chain(new BitPosCommand(args, this.commandOptions))
135
136
  });
137
+ /**
138
+ * @see https://redis.io/commands/zdiffstore
139
+ */
140
+ Object.defineProperty(this, "zdiffstore", {
141
+ enumerable: true,
142
+ configurable: true,
143
+ writable: true,
144
+ value: (...args) => this.chain(new ZDiffStoreCommand(args, this.commandOptions))
145
+ });
136
146
  /**
137
147
  * @see https://redis.io/commands/dbsize
138
148
  */
package/esm/pkg/redis.js CHANGED
@@ -2,6 +2,7 @@ import { AppendCommand, BitCountCommand, BitOpCommand, BitPosCommand, DBSizeComm
2
2
  import { Pipeline } from "./pipeline.js";
3
3
  import { Script } from "./script.js";
4
4
  import { ZMScoreCommand } from "./commands/zmscore.js";
5
+ import { ZDiffStoreCommand } from "./commands/zdiffstore.js";
5
6
  /**
6
7
  * Serverless redis client for upstash.
7
8
  */
@@ -1000,6 +1001,15 @@ export class Redis {
1000
1001
  writable: true,
1001
1002
  value: (...args) => new ZCountCommand(args, this.opts).exec(this.client)
1002
1003
  });
1004
+ /**
1005
+ * @see https://redis.io/commands/zdiffstore
1006
+ */
1007
+ Object.defineProperty(this, "zdiffstore", {
1008
+ enumerable: true,
1009
+ configurable: true,
1010
+ writable: true,
1011
+ value: (...args) => new ZDiffStoreCommand(args, this.opts).exec(this.client)
1012
+ });
1003
1013
  /**
1004
1014
  * @see https://redis.io/commands/zincrby
1005
1015
  */
package/esm/version.js CHANGED
@@ -1 +1 @@
1
- export const VERSION = "v1.18.5-rc.0";
1
+ export const VERSION = "v1.18.5";
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "main": "./script/platforms/nodejs.js",
4
4
  "types": "./types/platforms/nodejs.d.ts",
5
5
  "name": "@upstash/redis",
6
- "version": "v1.18.5-rc.0",
6
+ "version": "v1.18.5",
7
7
  "description": "An HTTP/REST based Redis client built on top of Upstash REST API.",
8
8
  "repository": {
9
9
  "type": "git",
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ZDiffStoreCommand = void 0;
4
+ const command_js_1 = require("./command.js");
5
+ /**
6
+ * @see https://redis.io/commands/zdiffstore
7
+ */
8
+ class ZDiffStoreCommand extends command_js_1.Command {
9
+ constructor(cmd, opts) {
10
+ super(["zdiffstore", ...cmd], opts);
11
+ }
12
+ }
13
+ exports.ZDiffStoreCommand = ZDiffStoreCommand;
@@ -5,6 +5,7 @@ const mod_js_1 = require("./commands/mod.js");
5
5
  const error_js_1 = require("./error.js");
6
6
  const zmscore_js_1 = require("./commands/zmscore.js");
7
7
  const hrandfield_js_1 = require("./commands/hrandfield.js");
8
+ const zdiffstore_js_1 = require("./commands/zdiffstore.js");
8
9
  /**
9
10
  * Upstash REST API supports command pipelining to send multiple commands in
10
11
  * batch, instead of sending each command one by one and waiting for a response.
@@ -136,6 +137,15 @@ class Pipeline {
136
137
  writable: true,
137
138
  value: (...args) => this.chain(new mod_js_1.BitPosCommand(args, this.commandOptions))
138
139
  });
140
+ /**
141
+ * @see https://redis.io/commands/zdiffstore
142
+ */
143
+ Object.defineProperty(this, "zdiffstore", {
144
+ enumerable: true,
145
+ configurable: true,
146
+ writable: true,
147
+ value: (...args) => this.chain(new zdiffstore_js_1.ZDiffStoreCommand(args, this.commandOptions))
148
+ });
139
149
  /**
140
150
  * @see https://redis.io/commands/dbsize
141
151
  */
@@ -5,6 +5,7 @@ const mod_js_1 = require("./commands/mod.js");
5
5
  const pipeline_js_1 = require("./pipeline.js");
6
6
  const script_js_1 = require("./script.js");
7
7
  const zmscore_js_1 = require("./commands/zmscore.js");
8
+ const zdiffstore_js_1 = require("./commands/zdiffstore.js");
8
9
  /**
9
10
  * Serverless redis client for upstash.
10
11
  */
@@ -1003,6 +1004,15 @@ class Redis {
1003
1004
  writable: true,
1004
1005
  value: (...args) => new mod_js_1.ZCountCommand(args, this.opts).exec(this.client)
1005
1006
  });
1007
+ /**
1008
+ * @see https://redis.io/commands/zdiffstore
1009
+ */
1010
+ Object.defineProperty(this, "zdiffstore", {
1011
+ enumerable: true,
1012
+ configurable: true,
1013
+ writable: true,
1014
+ value: (...args) => new zdiffstore_js_1.ZDiffStoreCommand(args, this.opts).exec(this.client)
1015
+ });
1006
1016
  /**
1007
1017
  * @see https://redis.io/commands/zincrby
1008
1018
  */
package/script/version.js CHANGED
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = "v1.18.5-rc.0";
4
+ exports.VERSION = "v1.18.5";
@@ -0,0 +1,7 @@
1
+ import { Command, CommandOptions } from "./command.js";
2
+ /**
3
+ * @see https://redis.io/commands/zdiffstore
4
+ */
5
+ export declare class ZDiffStoreCommand extends Command<number, number> {
6
+ constructor(cmd: [destination: string, numkeys: number, ...keys: string[]], opts?: CommandOptions<number, number>);
7
+ }
@@ -85,6 +85,10 @@ export declare class Pipeline {
85
85
  * @see https://redis.io/commands/bitpos
86
86
  */
87
87
  bitpos: (key: string, bit: 0 | 1, start?: number | undefined, end?: number | undefined) => this;
88
+ /**
89
+ * @see https://redis.io/commands/zdiffstore
90
+ */
91
+ zdiffstore: (destination: string, numkeys: number, ...keys: string[]) => this;
88
92
  /**
89
93
  * @see https://redis.io/commands/dbsize
90
94
  */
@@ -479,6 +479,10 @@ export declare class Redis {
479
479
  * @see https://redis.io/commands/zcount
480
480
  */
481
481
  zcount: (key: string, min: string | number, max: string | number) => Promise<number>;
482
+ /**
483
+ * @see https://redis.io/commands/zdiffstore
484
+ */
485
+ zdiffstore: (destination: string, numkeys: number, ...keys: string[]) => Promise<number>;
482
486
  /**
483
487
  * @see https://redis.io/commands/zincrby
484
488
  */
@@ -1 +1 @@
1
- export declare const VERSION = "v1.18.5-rc.0";
1
+ export declare const VERSION = "v1.18.5";