@upstash/redis 1.37.0-rc.8 → 1.37.0
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/{chunk-3HKMGXM7.mjs → chunk-IH7W44G6.mjs} +72 -31
- package/cloudflare.d.mts +2 -2
- package/cloudflare.d.ts +2 -2
- package/cloudflare.js +72 -31
- package/cloudflare.mjs +1 -1
- package/{zmscore-CjaAkTRU.d.mts → error-8y4qG0W2.d.mts} +677 -857
- package/{zmscore-CjaAkTRU.d.ts → error-8y4qG0W2.d.ts} +677 -857
- package/fastly.d.mts +2 -2
- package/fastly.d.ts +2 -2
- package/fastly.js +72 -31
- package/fastly.mjs +1 -1
- package/nodejs.d.mts +9 -3
- package/nodejs.d.ts +9 -3
- package/nodejs.js +81 -32
- package/nodejs.mjs +10 -2
- package/package.json +78 -1
package/fastly.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as
|
|
2
|
-
export { A as AppendCommand, B as BitCountCommand,
|
|
1
|
+
import { R as Redis$1, a as RedisOptions, b as RequesterConfig } from './error-8y4qG0W2.mjs';
|
|
2
|
+
export { A as AppendCommand, B as BitCountCommand, c as BitOpCommand, d as BitPosCommand, C as ClientSetInfoAttribute, e as ClientSetInfoCommand, f as CopyCommand, D as DBSizeCommand, g as DecrByCommand, h as DecrCommand, i as DelCommand, E as EchoCommand, j as EvalCommand, k as EvalROCommand, l as EvalshaCommand, m as EvalshaROCommand, n as ExistsCommand, o as ExpireAtCommand, p as ExpireCommand, q as ExpireOption, F as FlushAllCommand, r as FlushDBCommand, G as GeoAddCommand, s as GeoAddCommandOptions, t as GeoDistCommand, u as GeoHashCommand, v as GeoMember, w as GeoPosCommand, x as GeoSearchCommand, y as GeoSearchStoreCommand, z as GetBitCommand, I as GetCommand, J as GetDelCommand, K as GetExCommand, L as GetRangeCommand, M as GetSetCommand, N as HDelCommand, O as HExistsCommand, P as HExpireAtCommand, Q as HExpireCommand, S as HExpireTimeCommand, T as HGetAllCommand, U as HGetCommand, V as HGetDelCommand, W as HGetExCommand, X as HIncrByCommand, Y as HIncrByFloatCommand, Z as HKeysCommand, _ as HLenCommand, $ as HMGetCommand, a0 as HMSetCommand, a1 as HPExpireAtCommand, a2 as HPExpireCommand, a3 as HPExpireTimeCommand, a4 as HPTtlCommand, a5 as HPersistCommand, a6 as HRandFieldCommand, a7 as HScanCommand, a8 as HSetCommand, a9 as HSetExCommand, aa as HSetNXCommand, ab as HStrLenCommand, ac as HTtlCommand, ad as HValsCommand, ae as IncrByCommand, af as IncrByFloatCommand, ag as IncrCommand, ah as JsonArrAppendCommand, ai as JsonArrIndexCommand, aj as JsonArrInsertCommand, ak as JsonArrLenCommand, al as JsonArrPopCommand, am as JsonArrTrimCommand, an as JsonClearCommand, ao as JsonDelCommand, ap as JsonForgetCommand, aq as JsonGetCommand, ar as JsonMGetCommand, as as JsonMergeCommand, at as JsonNumIncrByCommand, au as JsonNumMultByCommand, av as JsonObjKeysCommand, aw as JsonObjLenCommand, ax as JsonRespCommand, ay as JsonSetCommand, az as JsonStrAppendCommand, aA as JsonStrLenCommand, aB as JsonToggleCommand, aC as JsonTypeCommand, aD as KeysCommand, aE as LIndexCommand, aF as LInsertCommand, aG as LLenCommand, aH as LMoveCommand, aI as LPopCommand, aJ as LPushCommand, aK as LPushXCommand, aL as LRangeCommand, aM as LRemCommand, aN as LSetCommand, aO as LTrimCommand, aP as MGetCommand, aQ as MSetCommand, aR as MSetNXCommand, aS as PExpireAtCommand, aT as PExpireCommand, aU as PSetEXCommand, aV as PTtlCommand, aW as PersistCommand, aX as PingCommand, aY as Pipeline, aZ as PublishCommand, a_ as RPopCommand, a$ as RPushCommand, b0 as RPushXCommand, b1 as RandomKeyCommand, b2 as RenameCommand, b3 as RenameNXCommand, b4 as Requester, b5 as SAddCommand, b6 as SCardCommand, b7 as SDiffCommand, b8 as SDiffStoreCommand, b9 as SInterCardCommand, ba as SInterCommand, bb as SInterStoreCommand, bc as SIsMemberCommand, bd as SMIsMemberCommand, be as SMembersCommand, bf as SMoveCommand, bg as SPopCommand, bh as SRandMemberCommand, bi as SRemCommand, bj as SScanCommand, bk as SUnionCommand, bl as SUnionStoreCommand, bm as ScanCommand, bn as ScanCommandOptions, bo as ScoreMember, bp as ScriptExistsCommand, bq as ScriptFlushCommand, br as ScriptLoadCommand, bs as SetBitCommand, bt as SetCommand, bu as SetCommandOptions, bv as SetExCommand, bw as SetNxCommand, bx as SetRangeCommand, by as StrLenCommand, bz as TimeCommand, bA as TouchCommand, bB as TtlCommand, bC as Type, bD as TypeCommand, bE as UnlinkCommand, bF as UpstashRequest, bG as UpstashResponse, bH as XAckDelCommand, bI as XAddCommand, bJ as XDelExCommand, bK as XRangeCommand, bL as ZAddCommand, bM as ZAddCommandOptions, bN as ZCardCommand, bO as ZCountCommand, bP as ZDiffStoreCommand, bQ as ZIncrByCommand, bR as ZInterStoreCommand, bS as ZInterStoreCommandOptions, bT as ZLexCountCommand, bU as ZMScoreCommand, bV as ZPopMaxCommand, bW as ZPopMinCommand, bX as ZRangeCommand, bY as ZRangeCommandOptions, bZ as ZRankCommand, b_ as ZRemCommand, b$ as ZRemRangeByLexCommand, c0 as ZRemRangeByRankCommand, c1 as ZRemRangeByScoreCommand, c2 as ZRevRankCommand, c3 as ZScanCommand, c4 as ZScoreCommand, c5 as ZUnionCommand, c6 as ZUnionCommandOptions, c7 as ZUnionStoreCommand, c8 as ZUnionStoreCommandOptions, c9 as errors } from './error-8y4qG0W2.mjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Connection credentials for upstash redis.
|
package/fastly.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as
|
|
2
|
-
export { A as AppendCommand, B as BitCountCommand,
|
|
1
|
+
import { R as Redis$1, a as RedisOptions, b as RequesterConfig } from './error-8y4qG0W2.js';
|
|
2
|
+
export { A as AppendCommand, B as BitCountCommand, c as BitOpCommand, d as BitPosCommand, C as ClientSetInfoAttribute, e as ClientSetInfoCommand, f as CopyCommand, D as DBSizeCommand, g as DecrByCommand, h as DecrCommand, i as DelCommand, E as EchoCommand, j as EvalCommand, k as EvalROCommand, l as EvalshaCommand, m as EvalshaROCommand, n as ExistsCommand, o as ExpireAtCommand, p as ExpireCommand, q as ExpireOption, F as FlushAllCommand, r as FlushDBCommand, G as GeoAddCommand, s as GeoAddCommandOptions, t as GeoDistCommand, u as GeoHashCommand, v as GeoMember, w as GeoPosCommand, x as GeoSearchCommand, y as GeoSearchStoreCommand, z as GetBitCommand, I as GetCommand, J as GetDelCommand, K as GetExCommand, L as GetRangeCommand, M as GetSetCommand, N as HDelCommand, O as HExistsCommand, P as HExpireAtCommand, Q as HExpireCommand, S as HExpireTimeCommand, T as HGetAllCommand, U as HGetCommand, V as HGetDelCommand, W as HGetExCommand, X as HIncrByCommand, Y as HIncrByFloatCommand, Z as HKeysCommand, _ as HLenCommand, $ as HMGetCommand, a0 as HMSetCommand, a1 as HPExpireAtCommand, a2 as HPExpireCommand, a3 as HPExpireTimeCommand, a4 as HPTtlCommand, a5 as HPersistCommand, a6 as HRandFieldCommand, a7 as HScanCommand, a8 as HSetCommand, a9 as HSetExCommand, aa as HSetNXCommand, ab as HStrLenCommand, ac as HTtlCommand, ad as HValsCommand, ae as IncrByCommand, af as IncrByFloatCommand, ag as IncrCommand, ah as JsonArrAppendCommand, ai as JsonArrIndexCommand, aj as JsonArrInsertCommand, ak as JsonArrLenCommand, al as JsonArrPopCommand, am as JsonArrTrimCommand, an as JsonClearCommand, ao as JsonDelCommand, ap as JsonForgetCommand, aq as JsonGetCommand, ar as JsonMGetCommand, as as JsonMergeCommand, at as JsonNumIncrByCommand, au as JsonNumMultByCommand, av as JsonObjKeysCommand, aw as JsonObjLenCommand, ax as JsonRespCommand, ay as JsonSetCommand, az as JsonStrAppendCommand, aA as JsonStrLenCommand, aB as JsonToggleCommand, aC as JsonTypeCommand, aD as KeysCommand, aE as LIndexCommand, aF as LInsertCommand, aG as LLenCommand, aH as LMoveCommand, aI as LPopCommand, aJ as LPushCommand, aK as LPushXCommand, aL as LRangeCommand, aM as LRemCommand, aN as LSetCommand, aO as LTrimCommand, aP as MGetCommand, aQ as MSetCommand, aR as MSetNXCommand, aS as PExpireAtCommand, aT as PExpireCommand, aU as PSetEXCommand, aV as PTtlCommand, aW as PersistCommand, aX as PingCommand, aY as Pipeline, aZ as PublishCommand, a_ as RPopCommand, a$ as RPushCommand, b0 as RPushXCommand, b1 as RandomKeyCommand, b2 as RenameCommand, b3 as RenameNXCommand, b4 as Requester, b5 as SAddCommand, b6 as SCardCommand, b7 as SDiffCommand, b8 as SDiffStoreCommand, b9 as SInterCardCommand, ba as SInterCommand, bb as SInterStoreCommand, bc as SIsMemberCommand, bd as SMIsMemberCommand, be as SMembersCommand, bf as SMoveCommand, bg as SPopCommand, bh as SRandMemberCommand, bi as SRemCommand, bj as SScanCommand, bk as SUnionCommand, bl as SUnionStoreCommand, bm as ScanCommand, bn as ScanCommandOptions, bo as ScoreMember, bp as ScriptExistsCommand, bq as ScriptFlushCommand, br as ScriptLoadCommand, bs as SetBitCommand, bt as SetCommand, bu as SetCommandOptions, bv as SetExCommand, bw as SetNxCommand, bx as SetRangeCommand, by as StrLenCommand, bz as TimeCommand, bA as TouchCommand, bB as TtlCommand, bC as Type, bD as TypeCommand, bE as UnlinkCommand, bF as UpstashRequest, bG as UpstashResponse, bH as XAckDelCommand, bI as XAddCommand, bJ as XDelExCommand, bK as XRangeCommand, bL as ZAddCommand, bM as ZAddCommandOptions, bN as ZCardCommand, bO as ZCountCommand, bP as ZDiffStoreCommand, bQ as ZIncrByCommand, bR as ZInterStoreCommand, bS as ZInterStoreCommandOptions, bT as ZLexCountCommand, bU as ZMScoreCommand, bV as ZPopMaxCommand, bW as ZPopMinCommand, bX as ZRangeCommand, bY as ZRangeCommandOptions, bZ as ZRankCommand, b_ as ZRemCommand, b$ as ZRemRangeByLexCommand, c0 as ZRemRangeByRankCommand, c1 as ZRemRangeByScoreCommand, c2 as ZRevRankCommand, c3 as ZScanCommand, c4 as ZScoreCommand, c5 as ZUnionCommand, c6 as ZUnionCommandOptions, c7 as ZUnionStoreCommand, c8 as ZUnionStoreCommandOptions, c9 as errors } from './error-8y4qG0W2.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Connection credentials for upstash redis.
|
package/fastly.js
CHANGED
|
@@ -163,7 +163,6 @@ var HttpClient = class {
|
|
|
163
163
|
const signal = req.signal ?? this.options.signal;
|
|
164
164
|
const isSignalFunction = typeof signal === "function";
|
|
165
165
|
const requestOptions = {
|
|
166
|
-
//@ts-expect-error this should throw due to bun regression
|
|
167
166
|
cache: this.options.cache,
|
|
168
167
|
method: "POST",
|
|
169
168
|
headers: requestHeaders,
|
|
@@ -2001,6 +2000,18 @@ var SInterCommand = class extends Command {
|
|
|
2001
2000
|
}
|
|
2002
2001
|
};
|
|
2003
2002
|
|
|
2003
|
+
// pkg/commands/sintercard.ts
|
|
2004
|
+
var SInterCardCommand = class extends Command {
|
|
2005
|
+
constructor(cmd, cmdOpts) {
|
|
2006
|
+
const [keys, opts] = cmd;
|
|
2007
|
+
const command = ["sintercard", keys.length, ...keys];
|
|
2008
|
+
if (opts?.limit !== void 0) {
|
|
2009
|
+
command.push("LIMIT", opts.limit);
|
|
2010
|
+
}
|
|
2011
|
+
super(command, cmdOpts);
|
|
2012
|
+
}
|
|
2013
|
+
};
|
|
2014
|
+
|
|
2004
2015
|
// pkg/commands/sinterstore.ts
|
|
2005
2016
|
var SInterStoreCommand = class extends Command {
|
|
2006
2017
|
constructor(cmd, opts) {
|
|
@@ -2150,8 +2161,7 @@ var XAckCommand = class extends Command {
|
|
|
2150
2161
|
var XAckDelCommand = class extends Command {
|
|
2151
2162
|
constructor([key, group, opts, ...ids], cmdOpts) {
|
|
2152
2163
|
const command = ["XACKDEL", key, group];
|
|
2153
|
-
command.push(opts.toUpperCase());
|
|
2154
|
-
command.push("IDS", ids.length, ...ids);
|
|
2164
|
+
command.push(opts.toUpperCase(), "IDS", ids.length, ...ids);
|
|
2155
2165
|
super(command, cmdOpts);
|
|
2156
2166
|
}
|
|
2157
2167
|
};
|
|
@@ -2693,7 +2703,16 @@ var ZUnionStoreCommand = class extends Command {
|
|
|
2693
2703
|
};
|
|
2694
2704
|
|
|
2695
2705
|
// pkg/commands/search/types.ts
|
|
2696
|
-
var FIELD_TYPES = [
|
|
2706
|
+
var FIELD_TYPES = [
|
|
2707
|
+
"TEXT",
|
|
2708
|
+
"U64",
|
|
2709
|
+
"I64",
|
|
2710
|
+
"F64",
|
|
2711
|
+
"BOOL",
|
|
2712
|
+
"DATE",
|
|
2713
|
+
"KEYWORD",
|
|
2714
|
+
"FACET"
|
|
2715
|
+
];
|
|
2697
2716
|
|
|
2698
2717
|
// pkg/commands/search/utils.ts
|
|
2699
2718
|
function isFieldType(value) {
|
|
@@ -2748,7 +2767,7 @@ function deserializeQueryResponse(rawResponse) {
|
|
|
2748
2767
|
const key2 = fieldRaw[0];
|
|
2749
2768
|
const value = fieldRaw[1];
|
|
2750
2769
|
const pathParts = key2.split(".");
|
|
2751
|
-
if (pathParts.length
|
|
2770
|
+
if (pathParts.length === 1) {
|
|
2752
2771
|
data[key2] = value;
|
|
2753
2772
|
} else {
|
|
2754
2773
|
let currentObj = data;
|
|
@@ -2810,6 +2829,10 @@ function deserializeDescribeResponse(rawResponse) {
|
|
|
2810
2829
|
fieldInfo.fast = true;
|
|
2811
2830
|
break;
|
|
2812
2831
|
}
|
|
2832
|
+
case "FROM": {
|
|
2833
|
+
fieldInfo.from = fieldDescription[++j];
|
|
2834
|
+
break;
|
|
2835
|
+
}
|
|
2813
2836
|
}
|
|
2814
2837
|
}
|
|
2815
2838
|
}
|
|
@@ -2825,16 +2848,8 @@ function deserializeDescribeResponse(rawResponse) {
|
|
|
2825
2848
|
function parseCountResponse(rawResponse) {
|
|
2826
2849
|
return typeof rawResponse === "number" ? rawResponse : Number.parseInt(rawResponse, 10);
|
|
2827
2850
|
}
|
|
2828
|
-
function deserializeAggregateResponse(rawResponse
|
|
2829
|
-
|
|
2830
|
-
const aggregationResult = parseAggregationArray(rawResponse[0]);
|
|
2831
|
-
const searchResults = deserializeQueryResponse(rawResponse[1]);
|
|
2832
|
-
return [aggregationResult, searchResults];
|
|
2833
|
-
}
|
|
2834
|
-
if (Array.isArray(rawResponse) && rawResponse.length === 1 && Array.isArray(rawResponse[0])) {
|
|
2835
|
-
return parseAggregationArray(rawResponse[0]);
|
|
2836
|
-
}
|
|
2837
|
-
return rawResponse;
|
|
2851
|
+
function deserializeAggregateResponse(rawResponse) {
|
|
2852
|
+
return parseAggregationArray(rawResponse);
|
|
2838
2853
|
}
|
|
2839
2854
|
function parseAggregationArray(arr) {
|
|
2840
2855
|
const result = {};
|
|
@@ -2853,6 +2868,12 @@ function parseAggregationArray(arr) {
|
|
|
2853
2868
|
}
|
|
2854
2869
|
return result;
|
|
2855
2870
|
}
|
|
2871
|
+
function coerceNumericString(value) {
|
|
2872
|
+
if (typeof value === "string" && value !== "" && !Number.isNaN(Number(value))) {
|
|
2873
|
+
return Number(value);
|
|
2874
|
+
}
|
|
2875
|
+
return value;
|
|
2876
|
+
}
|
|
2856
2877
|
function parseStatsValue(arr) {
|
|
2857
2878
|
const result = {};
|
|
2858
2879
|
for (let i = 0; i < arr.length; i += 2) {
|
|
@@ -2867,14 +2888,14 @@ function parseStatsValue(arr) {
|
|
|
2867
2888
|
result[key] = value;
|
|
2868
2889
|
}
|
|
2869
2890
|
} else {
|
|
2870
|
-
result[key] = value;
|
|
2891
|
+
result[key] = coerceNumericString(value);
|
|
2871
2892
|
}
|
|
2872
2893
|
}
|
|
2873
2894
|
return result;
|
|
2874
2895
|
}
|
|
2875
2896
|
function parseBucketsValue(arr) {
|
|
2876
2897
|
if (arr[0] === "buckets" && Array.isArray(arr[1])) {
|
|
2877
|
-
|
|
2898
|
+
const result = {
|
|
2878
2899
|
buckets: arr[1].map((bucket) => {
|
|
2879
2900
|
const bucketObj = {};
|
|
2880
2901
|
for (let i = 0; i < bucket.length; i += 2) {
|
|
@@ -2885,6 +2906,10 @@ function parseBucketsValue(arr) {
|
|
|
2885
2906
|
return bucketObj;
|
|
2886
2907
|
})
|
|
2887
2908
|
};
|
|
2909
|
+
for (let i = 2; i < arr.length; i += 2) {
|
|
2910
|
+
result[arr[i]] = arr[i + 1];
|
|
2911
|
+
}
|
|
2912
|
+
return result;
|
|
2888
2913
|
}
|
|
2889
2914
|
return arr;
|
|
2890
2915
|
}
|
|
@@ -3008,11 +3033,7 @@ function buildCreateIndexCommand(params) {
|
|
|
3008
3033
|
function buildAggregateCommand(name, options) {
|
|
3009
3034
|
const query = JSON.stringify(options?.filter ?? {});
|
|
3010
3035
|
const aggregations = JSON.stringify(options.aggregations);
|
|
3011
|
-
|
|
3012
|
-
if (options?.limit !== void 0) {
|
|
3013
|
-
command.push("LIMIT", options.limit.toString());
|
|
3014
|
-
}
|
|
3015
|
-
return command;
|
|
3036
|
+
return ["SEARCH.AGGREGATE", name, query, aggregations];
|
|
3016
3037
|
}
|
|
3017
3038
|
|
|
3018
3039
|
// pkg/commands/search/search.ts
|
|
@@ -3027,13 +3048,14 @@ var SearchIndex = class {
|
|
|
3027
3048
|
}
|
|
3028
3049
|
async waitIndexing() {
|
|
3029
3050
|
const command = ["SEARCH.WAITINDEXING", this.name];
|
|
3030
|
-
await new ExecCommand(command).exec(this.client);
|
|
3051
|
+
return await new ExecCommand(command).exec(this.client);
|
|
3031
3052
|
}
|
|
3032
3053
|
async describe() {
|
|
3033
3054
|
const command = ["SEARCH.DESCRIBE", this.name];
|
|
3034
3055
|
const rawResult = await new ExecCommand(command).exec(
|
|
3035
3056
|
this.client
|
|
3036
3057
|
);
|
|
3058
|
+
if (!rawResult) return null;
|
|
3037
3059
|
return deserializeDescribeResponse(rawResult);
|
|
3038
3060
|
}
|
|
3039
3061
|
async query(options) {
|
|
@@ -3041,6 +3063,7 @@ var SearchIndex = class {
|
|
|
3041
3063
|
const rawResult = await new ExecCommand(command).exec(
|
|
3042
3064
|
this.client
|
|
3043
3065
|
);
|
|
3066
|
+
if (!rawResult) return rawResult;
|
|
3044
3067
|
return deserializeQueryResponse(rawResult);
|
|
3045
3068
|
}
|
|
3046
3069
|
async aggregate(options) {
|
|
@@ -3048,7 +3071,7 @@ var SearchIndex = class {
|
|
|
3048
3071
|
const rawResult = await new ExecCommand(
|
|
3049
3072
|
command
|
|
3050
3073
|
).exec(this.client);
|
|
3051
|
-
return deserializeAggregateResponse(rawResult
|
|
3074
|
+
return deserializeAggregateResponse(rawResult);
|
|
3052
3075
|
}
|
|
3053
3076
|
async count({ filter }) {
|
|
3054
3077
|
const command = buildQueryCommand("SEARCH.COUNT", this.name, { filter });
|
|
@@ -3833,6 +3856,10 @@ var Pipeline = class {
|
|
|
3833
3856
|
* @see https://redis.io/commands/sinter
|
|
3834
3857
|
*/
|
|
3835
3858
|
sinter = (...args) => this.chain(new SInterCommand(args, this.commandOptions));
|
|
3859
|
+
/**
|
|
3860
|
+
* @see https://redis.io/commands/sintercard
|
|
3861
|
+
*/
|
|
3862
|
+
sintercard = (...args) => this.chain(new SInterCardCommand(args, this.commandOptions));
|
|
3836
3863
|
/**
|
|
3837
3864
|
* @see https://redis.io/commands/sinterstore
|
|
3838
3865
|
*/
|
|
@@ -4202,6 +4229,7 @@ var Script = class {
|
|
|
4202
4229
|
* future major release.
|
|
4203
4230
|
*/
|
|
4204
4231
|
sha1;
|
|
4232
|
+
initPromise;
|
|
4205
4233
|
redis;
|
|
4206
4234
|
constructor(redis, script) {
|
|
4207
4235
|
this.redis = redis;
|
|
@@ -4212,9 +4240,13 @@ var Script = class {
|
|
|
4212
4240
|
/**
|
|
4213
4241
|
* Initialize the script by computing its SHA-1 hash.
|
|
4214
4242
|
*/
|
|
4215
|
-
|
|
4216
|
-
if (this.
|
|
4217
|
-
|
|
4243
|
+
init(script) {
|
|
4244
|
+
if (!this.initPromise) {
|
|
4245
|
+
this.initPromise = this.digest(script).then((sha1) => {
|
|
4246
|
+
this.sha1 = sha1;
|
|
4247
|
+
});
|
|
4248
|
+
}
|
|
4249
|
+
return this.initPromise;
|
|
4218
4250
|
}
|
|
4219
4251
|
/**
|
|
4220
4252
|
* Send an `EVAL` command to redis.
|
|
@@ -4269,6 +4301,7 @@ var ScriptRO = class {
|
|
|
4269
4301
|
* future major release.
|
|
4270
4302
|
*/
|
|
4271
4303
|
sha1;
|
|
4304
|
+
initPromise;
|
|
4272
4305
|
redis;
|
|
4273
4306
|
constructor(redis, script) {
|
|
4274
4307
|
this.redis = redis;
|
|
@@ -4276,9 +4309,13 @@ var ScriptRO = class {
|
|
|
4276
4309
|
this.script = script;
|
|
4277
4310
|
void this.init(script);
|
|
4278
4311
|
}
|
|
4279
|
-
|
|
4280
|
-
if (this.
|
|
4281
|
-
|
|
4312
|
+
init(script) {
|
|
4313
|
+
if (!this.initPromise) {
|
|
4314
|
+
this.initPromise = this.digest(script).then((sha1) => {
|
|
4315
|
+
this.sha1 = sha1;
|
|
4316
|
+
});
|
|
4317
|
+
}
|
|
4318
|
+
return this.initPromise;
|
|
4282
4319
|
}
|
|
4283
4320
|
/**
|
|
4284
4321
|
* Send an `EVAL_RO` command to redis.
|
|
@@ -5049,6 +5086,10 @@ var Redis = class {
|
|
|
5049
5086
|
* @see https://redis.io/commands/sinter
|
|
5050
5087
|
*/
|
|
5051
5088
|
sinter = (...args) => new SInterCommand(args, this.opts).exec(this.client);
|
|
5089
|
+
/**
|
|
5090
|
+
* @see https://redis.io/commands/sintercard
|
|
5091
|
+
*/
|
|
5092
|
+
sintercard = (...args) => new SInterCardCommand(args, this.opts).exec(this.client);
|
|
5052
5093
|
/**
|
|
5053
5094
|
* @see https://redis.io/commands/sinterstore
|
|
5054
5095
|
*/
|
|
@@ -5285,7 +5326,7 @@ var Redis = class {
|
|
|
5285
5326
|
};
|
|
5286
5327
|
|
|
5287
5328
|
// version.ts
|
|
5288
|
-
var VERSION = "v1.
|
|
5329
|
+
var VERSION = "v1.30.2";
|
|
5289
5330
|
|
|
5290
5331
|
// platforms/fastly.ts
|
|
5291
5332
|
var Redis2 = class extends Redis {
|
package/fastly.mjs
CHANGED
package/nodejs.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { A as AppendCommand, B as BitCountCommand,
|
|
1
|
+
import { ca as NumericField, cb as NestedIndexSchema, R as Redis$1, H as HttpClientConfig, a as RedisOptions, b as RequesterConfig, b4 as Requester } from './error-8y4qG0W2.mjs';
|
|
2
|
+
export { A as AppendCommand, B as BitCountCommand, c as BitOpCommand, d as BitPosCommand, C as ClientSetInfoAttribute, e as ClientSetInfoCommand, f as CopyCommand, cc as CreateIndexParameters, D as DBSizeCommand, g as DecrByCommand, h as DecrCommand, i as DelCommand, E as EchoCommand, j as EvalCommand, k as EvalROCommand, l as EvalshaCommand, m as EvalshaROCommand, n as ExistsCommand, o as ExpireAtCommand, p as ExpireCommand, q as ExpireOption, cd as FlatIndexSchema, F as FlushAllCommand, r as FlushDBCommand, G as GeoAddCommand, s as GeoAddCommandOptions, t as GeoDistCommand, u as GeoHashCommand, v as GeoMember, w as GeoPosCommand, x as GeoSearchCommand, y as GeoSearchStoreCommand, z as GetBitCommand, I as GetCommand, J as GetDelCommand, K as GetExCommand, L as GetRangeCommand, M as GetSetCommand, N as HDelCommand, O as HExistsCommand, P as HExpireAtCommand, Q as HExpireCommand, S as HExpireTimeCommand, T as HGetAllCommand, U as HGetCommand, V as HGetDelCommand, W as HGetExCommand, X as HIncrByCommand, Y as HIncrByFloatCommand, Z as HKeysCommand, _ as HLenCommand, $ as HMGetCommand, a0 as HMSetCommand, a1 as HPExpireAtCommand, a2 as HPExpireCommand, a3 as HPExpireTimeCommand, a4 as HPTtlCommand, a5 as HPersistCommand, a6 as HRandFieldCommand, a7 as HScanCommand, a8 as HSetCommand, a9 as HSetExCommand, aa as HSetNXCommand, ab as HStrLenCommand, ac as HTtlCommand, ad as HValsCommand, ae as IncrByCommand, af as IncrByFloatCommand, ag as IncrCommand, ce as InferFilterFromSchema, ah as JsonArrAppendCommand, ai as JsonArrIndexCommand, aj as JsonArrInsertCommand, ak as JsonArrLenCommand, al as JsonArrPopCommand, am as JsonArrTrimCommand, an as JsonClearCommand, ao as JsonDelCommand, ap as JsonForgetCommand, aq as JsonGetCommand, ar as JsonMGetCommand, as as JsonMergeCommand, at as JsonNumIncrByCommand, au as JsonNumMultByCommand, av as JsonObjKeysCommand, aw as JsonObjLenCommand, ax as JsonRespCommand, ay as JsonSetCommand, az as JsonStrAppendCommand, aA as JsonStrLenCommand, aB as JsonToggleCommand, aC as JsonTypeCommand, aD as KeysCommand, aE as LIndexCommand, aF as LInsertCommand, aG as LLenCommand, aH as LMoveCommand, aI as LPopCommand, aJ as LPushCommand, aK as LPushXCommand, aL as LRangeCommand, aM as LRemCommand, aN as LSetCommand, aO as LTrimCommand, aP as MGetCommand, aQ as MSetCommand, aR as MSetNXCommand, aS as PExpireAtCommand, aT as PExpireCommand, aU as PSetEXCommand, aV as PTtlCommand, aW as PersistCommand, aX as PingCommand, aY as Pipeline, aZ as PublishCommand, cf as QueryResult, a_ as RPopCommand, a$ as RPushCommand, b0 as RPushXCommand, b1 as RandomKeyCommand, b2 as RenameCommand, b3 as RenameNXCommand, b5 as SAddCommand, b6 as SCardCommand, b7 as SDiffCommand, b8 as SDiffStoreCommand, b9 as SInterCardCommand, ba as SInterCommand, bb as SInterStoreCommand, bc as SIsMemberCommand, bd as SMIsMemberCommand, be as SMembersCommand, bf as SMoveCommand, bg as SPopCommand, bh as SRandMemberCommand, bi as SRemCommand, bj as SScanCommand, bk as SUnionCommand, bl as SUnionStoreCommand, bm as ScanCommand, bn as ScanCommandOptions, bo as ScoreMember, bp as ScriptExistsCommand, bq as ScriptFlushCommand, br as ScriptLoadCommand, cg as SearchIndex, ch as SearchIndexParameters, bs as SetBitCommand, bt as SetCommand, bu as SetCommandOptions, bv as SetExCommand, bw as SetNxCommand, bx as SetRangeCommand, by as StrLenCommand, bz as TimeCommand, bA as TouchCommand, bB as TtlCommand, bC as Type, bD as TypeCommand, bE as UnlinkCommand, bF as UpstashRequest, bG as UpstashResponse, bH as XAckDelCommand, bI as XAddCommand, bJ as XDelExCommand, bK as XRangeCommand, bL as ZAddCommand, bM as ZAddCommandOptions, bN as ZCardCommand, bO as ZCountCommand, bP as ZDiffStoreCommand, bQ as ZIncrByCommand, bR as ZInterStoreCommand, bS as ZInterStoreCommandOptions, bT as ZLexCountCommand, bU as ZMScoreCommand, bV as ZPopMaxCommand, bW as ZPopMinCommand, bX as ZRangeCommand, bY as ZRangeCommandOptions, bZ as ZRankCommand, b_ as ZRemCommand, b$ as ZRemRangeByLexCommand, c0 as ZRemRangeByRankCommand, c1 as ZRemRangeByScoreCommand, c2 as ZRevRankCommand, c3 as ZScanCommand, c4 as ZScoreCommand, c5 as ZUnionCommand, c6 as ZUnionCommandOptions, c7 as ZUnionStoreCommand, c8 as ZUnionStoreCommandOptions, c9 as errors } from './error-8y4qG0W2.mjs';
|
|
3
3
|
|
|
4
4
|
type TextFieldBuild<TNoTokenize extends Record<"noTokenize", boolean>, TNoStem extends Record<"noStem", boolean>, TFrom extends Record<"from", string | null>> = TNoTokenize["noTokenize"] extends true ? {
|
|
5
5
|
type: "TEXT";
|
|
@@ -125,6 +125,11 @@ declare class KeywordFieldBuilder {
|
|
|
125
125
|
type: "KEYWORD";
|
|
126
126
|
};
|
|
127
127
|
}
|
|
128
|
+
declare class FacetFieldBuilder {
|
|
129
|
+
[BUILD](): {
|
|
130
|
+
type: "FACET";
|
|
131
|
+
};
|
|
132
|
+
}
|
|
128
133
|
type FieldBuilder = TextFieldBuilder<{
|
|
129
134
|
noTokenize: boolean;
|
|
130
135
|
}, {
|
|
@@ -141,13 +146,14 @@ type FieldBuilder = TextFieldBuilder<{
|
|
|
141
146
|
fast: boolean;
|
|
142
147
|
}, {
|
|
143
148
|
from: string | null;
|
|
144
|
-
}> | KeywordFieldBuilder;
|
|
149
|
+
}> | KeywordFieldBuilder | FacetFieldBuilder;
|
|
145
150
|
declare const s: {
|
|
146
151
|
string(): TextFieldBuilder;
|
|
147
152
|
number<T extends NumericField["type"] = "F64">(type?: T): NumericFieldBuilder<T>;
|
|
148
153
|
boolean(): BoolFieldBuilder;
|
|
149
154
|
date(): DateFieldBuilder;
|
|
150
155
|
keyword(): KeywordFieldBuilder;
|
|
156
|
+
facet(): FacetFieldBuilder;
|
|
151
157
|
object<T extends ObjectFieldRecord<T>>(fields: T): { [K in keyof T]: T[K] extends FieldBuilder ? ReturnType<T[K][typeof BUILD]> : T[K]; };
|
|
152
158
|
};
|
|
153
159
|
type ObjectFieldRecord<T> = {
|
package/nodejs.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { A as AppendCommand, B as BitCountCommand,
|
|
1
|
+
import { ca as NumericField, cb as NestedIndexSchema, R as Redis$1, H as HttpClientConfig, a as RedisOptions, b as RequesterConfig, b4 as Requester } from './error-8y4qG0W2.js';
|
|
2
|
+
export { A as AppendCommand, B as BitCountCommand, c as BitOpCommand, d as BitPosCommand, C as ClientSetInfoAttribute, e as ClientSetInfoCommand, f as CopyCommand, cc as CreateIndexParameters, D as DBSizeCommand, g as DecrByCommand, h as DecrCommand, i as DelCommand, E as EchoCommand, j as EvalCommand, k as EvalROCommand, l as EvalshaCommand, m as EvalshaROCommand, n as ExistsCommand, o as ExpireAtCommand, p as ExpireCommand, q as ExpireOption, cd as FlatIndexSchema, F as FlushAllCommand, r as FlushDBCommand, G as GeoAddCommand, s as GeoAddCommandOptions, t as GeoDistCommand, u as GeoHashCommand, v as GeoMember, w as GeoPosCommand, x as GeoSearchCommand, y as GeoSearchStoreCommand, z as GetBitCommand, I as GetCommand, J as GetDelCommand, K as GetExCommand, L as GetRangeCommand, M as GetSetCommand, N as HDelCommand, O as HExistsCommand, P as HExpireAtCommand, Q as HExpireCommand, S as HExpireTimeCommand, T as HGetAllCommand, U as HGetCommand, V as HGetDelCommand, W as HGetExCommand, X as HIncrByCommand, Y as HIncrByFloatCommand, Z as HKeysCommand, _ as HLenCommand, $ as HMGetCommand, a0 as HMSetCommand, a1 as HPExpireAtCommand, a2 as HPExpireCommand, a3 as HPExpireTimeCommand, a4 as HPTtlCommand, a5 as HPersistCommand, a6 as HRandFieldCommand, a7 as HScanCommand, a8 as HSetCommand, a9 as HSetExCommand, aa as HSetNXCommand, ab as HStrLenCommand, ac as HTtlCommand, ad as HValsCommand, ae as IncrByCommand, af as IncrByFloatCommand, ag as IncrCommand, ce as InferFilterFromSchema, ah as JsonArrAppendCommand, ai as JsonArrIndexCommand, aj as JsonArrInsertCommand, ak as JsonArrLenCommand, al as JsonArrPopCommand, am as JsonArrTrimCommand, an as JsonClearCommand, ao as JsonDelCommand, ap as JsonForgetCommand, aq as JsonGetCommand, ar as JsonMGetCommand, as as JsonMergeCommand, at as JsonNumIncrByCommand, au as JsonNumMultByCommand, av as JsonObjKeysCommand, aw as JsonObjLenCommand, ax as JsonRespCommand, ay as JsonSetCommand, az as JsonStrAppendCommand, aA as JsonStrLenCommand, aB as JsonToggleCommand, aC as JsonTypeCommand, aD as KeysCommand, aE as LIndexCommand, aF as LInsertCommand, aG as LLenCommand, aH as LMoveCommand, aI as LPopCommand, aJ as LPushCommand, aK as LPushXCommand, aL as LRangeCommand, aM as LRemCommand, aN as LSetCommand, aO as LTrimCommand, aP as MGetCommand, aQ as MSetCommand, aR as MSetNXCommand, aS as PExpireAtCommand, aT as PExpireCommand, aU as PSetEXCommand, aV as PTtlCommand, aW as PersistCommand, aX as PingCommand, aY as Pipeline, aZ as PublishCommand, cf as QueryResult, a_ as RPopCommand, a$ as RPushCommand, b0 as RPushXCommand, b1 as RandomKeyCommand, b2 as RenameCommand, b3 as RenameNXCommand, b5 as SAddCommand, b6 as SCardCommand, b7 as SDiffCommand, b8 as SDiffStoreCommand, b9 as SInterCardCommand, ba as SInterCommand, bb as SInterStoreCommand, bc as SIsMemberCommand, bd as SMIsMemberCommand, be as SMembersCommand, bf as SMoveCommand, bg as SPopCommand, bh as SRandMemberCommand, bi as SRemCommand, bj as SScanCommand, bk as SUnionCommand, bl as SUnionStoreCommand, bm as ScanCommand, bn as ScanCommandOptions, bo as ScoreMember, bp as ScriptExistsCommand, bq as ScriptFlushCommand, br as ScriptLoadCommand, cg as SearchIndex, ch as SearchIndexParameters, bs as SetBitCommand, bt as SetCommand, bu as SetCommandOptions, bv as SetExCommand, bw as SetNxCommand, bx as SetRangeCommand, by as StrLenCommand, bz as TimeCommand, bA as TouchCommand, bB as TtlCommand, bC as Type, bD as TypeCommand, bE as UnlinkCommand, bF as UpstashRequest, bG as UpstashResponse, bH as XAckDelCommand, bI as XAddCommand, bJ as XDelExCommand, bK as XRangeCommand, bL as ZAddCommand, bM as ZAddCommandOptions, bN as ZCardCommand, bO as ZCountCommand, bP as ZDiffStoreCommand, bQ as ZIncrByCommand, bR as ZInterStoreCommand, bS as ZInterStoreCommandOptions, bT as ZLexCountCommand, bU as ZMScoreCommand, bV as ZPopMaxCommand, bW as ZPopMinCommand, bX as ZRangeCommand, bY as ZRangeCommandOptions, bZ as ZRankCommand, b_ as ZRemCommand, b$ as ZRemRangeByLexCommand, c0 as ZRemRangeByRankCommand, c1 as ZRemRangeByScoreCommand, c2 as ZRevRankCommand, c3 as ZScanCommand, c4 as ZScoreCommand, c5 as ZUnionCommand, c6 as ZUnionCommandOptions, c7 as ZUnionStoreCommand, c8 as ZUnionStoreCommandOptions, c9 as errors } from './error-8y4qG0W2.js';
|
|
3
3
|
|
|
4
4
|
type TextFieldBuild<TNoTokenize extends Record<"noTokenize", boolean>, TNoStem extends Record<"noStem", boolean>, TFrom extends Record<"from", string | null>> = TNoTokenize["noTokenize"] extends true ? {
|
|
5
5
|
type: "TEXT";
|
|
@@ -125,6 +125,11 @@ declare class KeywordFieldBuilder {
|
|
|
125
125
|
type: "KEYWORD";
|
|
126
126
|
};
|
|
127
127
|
}
|
|
128
|
+
declare class FacetFieldBuilder {
|
|
129
|
+
[BUILD](): {
|
|
130
|
+
type: "FACET";
|
|
131
|
+
};
|
|
132
|
+
}
|
|
128
133
|
type FieldBuilder = TextFieldBuilder<{
|
|
129
134
|
noTokenize: boolean;
|
|
130
135
|
}, {
|
|
@@ -141,13 +146,14 @@ type FieldBuilder = TextFieldBuilder<{
|
|
|
141
146
|
fast: boolean;
|
|
142
147
|
}, {
|
|
143
148
|
from: string | null;
|
|
144
|
-
}> | KeywordFieldBuilder;
|
|
149
|
+
}> | KeywordFieldBuilder | FacetFieldBuilder;
|
|
145
150
|
declare const s: {
|
|
146
151
|
string(): TextFieldBuilder;
|
|
147
152
|
number<T extends NumericField["type"] = "F64">(type?: T): NumericFieldBuilder<T>;
|
|
148
153
|
boolean(): BoolFieldBuilder;
|
|
149
154
|
date(): DateFieldBuilder;
|
|
150
155
|
keyword(): KeywordFieldBuilder;
|
|
156
|
+
facet(): FacetFieldBuilder;
|
|
151
157
|
object<T extends ObjectFieldRecord<T>>(fields: T): { [K in keyof T]: T[K] extends FieldBuilder ? ReturnType<T[K][typeof BUILD]> : T[K]; };
|
|
152
158
|
};
|
|
153
159
|
type ObjectFieldRecord<T> = {
|