@milkio/redis 1.0.0-beta.99 → 1.0.1
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/LICENSE +20 -20
- package/index.d.ts +19 -303
- package/index.js +103 -51
- package/package.json +12 -1
- package/chunk-6sxyen7j.js +0 -24
- package/chunk-xt8gwvgg.js +0 -16021
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2023 akirarika
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2023 akirarika
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
21
|
SOFTWARE.
|
package/index.d.ts
CHANGED
|
@@ -1,324 +1,34 @@
|
|
|
1
|
-
import type { RedisClientOptions } from "redis";
|
|
2
1
|
export type MilkioRedisCacheOptions<T> = {
|
|
3
2
|
defaultValue?: T | undefined;
|
|
4
|
-
expireMs: number;
|
|
3
|
+
expireMs: number | null;
|
|
5
4
|
};
|
|
6
5
|
export type MilkioRedisFetchOptions<T> = {
|
|
7
6
|
defaultValue?: T | undefined;
|
|
8
|
-
expireMs: number;
|
|
9
|
-
realExpireMs?: number;
|
|
7
|
+
expireMs: number | null;
|
|
8
|
+
realExpireMs?: number | null;
|
|
10
9
|
lockInterval?: number;
|
|
11
10
|
refreshLockInterval?: number;
|
|
12
|
-
notFoundExpireMs?: number;
|
|
11
|
+
notFoundExpireMs?: number | null;
|
|
13
12
|
fetch: () => T | undefined | Promise<T | undefined>;
|
|
14
13
|
};
|
|
15
|
-
export
|
|
16
|
-
redis:
|
|
17
|
-
graph: {
|
|
18
|
-
CONFIG_GET: typeof import("@redis/graph/dist/commands/CONFIG_GET.js");
|
|
19
|
-
configGet: typeof import("@redis/graph/dist/commands/CONFIG_GET.js");
|
|
20
|
-
CONFIG_SET: typeof import("@redis/graph/dist/commands/CONFIG_SET.js");
|
|
21
|
-
configSet: typeof import("@redis/graph/dist/commands/CONFIG_SET.js");
|
|
22
|
-
DELETE: typeof import("@redis/graph/dist/commands/DELETE.js");
|
|
23
|
-
delete: typeof import("@redis/graph/dist/commands/DELETE.js");
|
|
24
|
-
EXPLAIN: typeof import("@redis/graph/dist/commands/EXPLAIN.js");
|
|
25
|
-
explain: typeof import("@redis/graph/dist/commands/EXPLAIN.js");
|
|
26
|
-
LIST: typeof import("@redis/graph/dist/commands/LIST.js");
|
|
27
|
-
list: typeof import("@redis/graph/dist/commands/LIST.js");
|
|
28
|
-
PROFILE: typeof import("@redis/graph/dist/commands/PROFILE.js");
|
|
29
|
-
profile: typeof import("@redis/graph/dist/commands/PROFILE.js");
|
|
30
|
-
QUERY: typeof import("@redis/graph/dist/commands/QUERY.js");
|
|
31
|
-
query: typeof import("@redis/graph/dist/commands/QUERY.js");
|
|
32
|
-
RO_QUERY: typeof import("@redis/graph/dist/commands/RO_QUERY.js");
|
|
33
|
-
roQuery: typeof import("@redis/graph/dist/commands/RO_QUERY.js");
|
|
34
|
-
SLOWLOG: typeof import("@redis/graph/dist/commands/SLOWLOG.js");
|
|
35
|
-
slowLog: typeof import("@redis/graph/dist/commands/SLOWLOG.js");
|
|
36
|
-
};
|
|
37
|
-
json: {
|
|
38
|
-
ARRAPPEND: typeof import("@redis/json/dist/commands/ARRAPPEND.js");
|
|
39
|
-
arrAppend: typeof import("@redis/json/dist/commands/ARRAPPEND.js");
|
|
40
|
-
ARRINDEX: typeof import("@redis/json/dist/commands/ARRINDEX.js");
|
|
41
|
-
arrIndex: typeof import("@redis/json/dist/commands/ARRINDEX.js");
|
|
42
|
-
ARRINSERT: typeof import("@redis/json/dist/commands/ARRINSERT.js");
|
|
43
|
-
arrInsert: typeof import("@redis/json/dist/commands/ARRINSERT.js");
|
|
44
|
-
ARRLEN: typeof import("@redis/json/dist/commands/ARRLEN.js");
|
|
45
|
-
arrLen: typeof import("@redis/json/dist/commands/ARRLEN.js");
|
|
46
|
-
ARRPOP: typeof import("@redis/json/dist/commands/ARRPOP.js");
|
|
47
|
-
arrPop: typeof import("@redis/json/dist/commands/ARRPOP.js");
|
|
48
|
-
ARRTRIM: typeof import("@redis/json/dist/commands/ARRTRIM.js");
|
|
49
|
-
arrTrim: typeof import("@redis/json/dist/commands/ARRTRIM.js");
|
|
50
|
-
DEBUG_MEMORY: typeof import("@redis/json/dist/commands/DEBUG_MEMORY.js");
|
|
51
|
-
debugMemory: typeof import("@redis/json/dist/commands/DEBUG_MEMORY.js");
|
|
52
|
-
DEL: typeof import("@redis/json/dist/commands/DEL.js");
|
|
53
|
-
del: typeof import("@redis/json/dist/commands/DEL.js");
|
|
54
|
-
FORGET: typeof import("@redis/json/dist/commands/FORGET.js");
|
|
55
|
-
forget: typeof import("@redis/json/dist/commands/FORGET.js");
|
|
56
|
-
GET: typeof import("@redis/json/dist/commands/GET.js");
|
|
57
|
-
get: typeof import("@redis/json/dist/commands/GET.js");
|
|
58
|
-
MERGE: typeof import("@redis/json/dist/commands/MERGE.js");
|
|
59
|
-
merge: typeof import("@redis/json/dist/commands/MERGE.js");
|
|
60
|
-
MGET: typeof import("@redis/json/dist/commands/MGET.js");
|
|
61
|
-
mGet: typeof import("@redis/json/dist/commands/MGET.js");
|
|
62
|
-
MSET: typeof import("@redis/json/dist/commands/MSET.js");
|
|
63
|
-
mSet: typeof import("@redis/json/dist/commands/MSET.js");
|
|
64
|
-
NUMINCRBY: typeof import("@redis/json/dist/commands/NUMINCRBY.js");
|
|
65
|
-
numIncrBy: typeof import("@redis/json/dist/commands/NUMINCRBY.js");
|
|
66
|
-
NUMMULTBY: typeof import("@redis/json/dist/commands/NUMMULTBY.js");
|
|
67
|
-
numMultBy: typeof import("@redis/json/dist/commands/NUMMULTBY.js");
|
|
68
|
-
OBJKEYS: typeof import("@redis/json/dist/commands/OBJKEYS.js");
|
|
69
|
-
objKeys: typeof import("@redis/json/dist/commands/OBJKEYS.js");
|
|
70
|
-
OBJLEN: typeof import("@redis/json/dist/commands/OBJLEN.js");
|
|
71
|
-
objLen: typeof import("@redis/json/dist/commands/OBJLEN.js");
|
|
72
|
-
RESP: typeof import("@redis/json/dist/commands/RESP.js");
|
|
73
|
-
resp: typeof import("@redis/json/dist/commands/RESP.js");
|
|
74
|
-
SET: typeof import("@redis/json/dist/commands/SET.js");
|
|
75
|
-
set: typeof import("@redis/json/dist/commands/SET.js");
|
|
76
|
-
STRAPPEND: typeof import("@redis/json/dist/commands/STRAPPEND.js");
|
|
77
|
-
strAppend: typeof import("@redis/json/dist/commands/STRAPPEND.js");
|
|
78
|
-
STRLEN: typeof import("@redis/json/dist/commands/STRLEN.js");
|
|
79
|
-
strLen: typeof import("@redis/json/dist/commands/STRLEN.js");
|
|
80
|
-
TYPE: typeof import("@redis/json/dist/commands/TYPE.js");
|
|
81
|
-
type: typeof import("@redis/json/dist/commands/TYPE.js");
|
|
82
|
-
};
|
|
83
|
-
ft: {
|
|
84
|
-
_LIST: typeof import("@redis/search/dist/commands/_LIST.js");
|
|
85
|
-
_list: typeof import("@redis/search/dist/commands/_LIST.js");
|
|
86
|
-
ALTER: typeof import("@redis/search/dist/commands/ALTER.js");
|
|
87
|
-
alter: typeof import("@redis/search/dist/commands/ALTER.js");
|
|
88
|
-
AGGREGATE_WITHCURSOR: typeof import("@redis/search/dist/commands/AGGREGATE_WITHCURSOR.js");
|
|
89
|
-
aggregateWithCursor: typeof import("@redis/search/dist/commands/AGGREGATE_WITHCURSOR.js");
|
|
90
|
-
AGGREGATE: typeof import("@redis/search/dist/commands/AGGREGATE.js");
|
|
91
|
-
aggregate: typeof import("@redis/search/dist/commands/AGGREGATE.js");
|
|
92
|
-
ALIASADD: typeof import("@redis/search/dist/commands/ALIASADD.js");
|
|
93
|
-
aliasAdd: typeof import("@redis/search/dist/commands/ALIASADD.js");
|
|
94
|
-
ALIASDEL: typeof import("@redis/search/dist/commands/ALIASDEL.js");
|
|
95
|
-
aliasDel: typeof import("@redis/search/dist/commands/ALIASDEL.js");
|
|
96
|
-
ALIASUPDATE: typeof import("@redis/search/dist/commands/ALIASUPDATE.js");
|
|
97
|
-
aliasUpdate: typeof import("@redis/search/dist/commands/ALIASUPDATE.js");
|
|
98
|
-
CONFIG_GET: typeof import("@redis/search/dist/commands/CONFIG_GET.js");
|
|
99
|
-
configGet: typeof import("@redis/search/dist/commands/CONFIG_GET.js");
|
|
100
|
-
CONFIG_SET: typeof import("@redis/search/dist/commands/CONFIG_SET.js");
|
|
101
|
-
configSet: typeof import("@redis/search/dist/commands/CONFIG_SET.js");
|
|
102
|
-
CREATE: typeof import("@redis/search/dist/commands/CREATE.js");
|
|
103
|
-
create: typeof import("@redis/search/dist/commands/CREATE.js");
|
|
104
|
-
CURSOR_DEL: typeof import("@redis/search/dist/commands/CURSOR_DEL.js");
|
|
105
|
-
cursorDel: typeof import("@redis/search/dist/commands/CURSOR_DEL.js");
|
|
106
|
-
CURSOR_READ: typeof import("@redis/search/dist/commands/CURSOR_READ.js");
|
|
107
|
-
cursorRead: typeof import("@redis/search/dist/commands/CURSOR_READ.js");
|
|
108
|
-
DICTADD: typeof import("@redis/search/dist/commands/DICTADD.js");
|
|
109
|
-
dictAdd: typeof import("@redis/search/dist/commands/DICTADD.js");
|
|
110
|
-
DICTDEL: typeof import("@redis/search/dist/commands/DICTDEL.js");
|
|
111
|
-
dictDel: typeof import("@redis/search/dist/commands/DICTDEL.js");
|
|
112
|
-
DICTDUMP: typeof import("@redis/search/dist/commands/DICTDUMP.js");
|
|
113
|
-
dictDump: typeof import("@redis/search/dist/commands/DICTDUMP.js");
|
|
114
|
-
DROPINDEX: typeof import("@redis/search/dist/commands/DROPINDEX.js");
|
|
115
|
-
dropIndex: typeof import("@redis/search/dist/commands/DROPINDEX.js");
|
|
116
|
-
EXPLAIN: typeof import("@redis/search/dist/commands/EXPLAIN.js");
|
|
117
|
-
explain: typeof import("@redis/search/dist/commands/EXPLAIN.js");
|
|
118
|
-
EXPLAINCLI: typeof import("@redis/search/dist/commands/EXPLAINCLI.js");
|
|
119
|
-
explainCli: typeof import("@redis/search/dist/commands/EXPLAINCLI.js");
|
|
120
|
-
INFO: typeof import("@redis/search/dist/commands/INFO.js");
|
|
121
|
-
info: typeof import("@redis/search/dist/commands/INFO.js");
|
|
122
|
-
PROFILESEARCH: typeof import("@redis/search/dist/commands/PROFILE_SEARCH.js");
|
|
123
|
-
profileSearch: typeof import("@redis/search/dist/commands/PROFILE_SEARCH.js");
|
|
124
|
-
PROFILEAGGREGATE: typeof import("@redis/search/dist/commands/PROFILE_AGGREGATE.js");
|
|
125
|
-
profileAggregate: typeof import("@redis/search/dist/commands/PROFILE_AGGREGATE.js");
|
|
126
|
-
SEARCH: typeof import("@redis/search/dist/commands/SEARCH.js");
|
|
127
|
-
search: typeof import("@redis/search/dist/commands/SEARCH.js");
|
|
128
|
-
SEARCH_NOCONTENT: typeof import("@redis/search/dist/commands/SEARCH_NOCONTENT.js");
|
|
129
|
-
searchNoContent: typeof import("@redis/search/dist/commands/SEARCH_NOCONTENT.js");
|
|
130
|
-
SPELLCHECK: typeof import("@redis/search/dist/commands/SPELLCHECK.js");
|
|
131
|
-
spellCheck: typeof import("@redis/search/dist/commands/SPELLCHECK.js");
|
|
132
|
-
SUGADD: typeof import("@redis/search/dist/commands/SUGADD.js");
|
|
133
|
-
sugAdd: typeof import("@redis/search/dist/commands/SUGADD.js");
|
|
134
|
-
SUGDEL: typeof import("@redis/search/dist/commands/SUGDEL.js");
|
|
135
|
-
sugDel: typeof import("@redis/search/dist/commands/SUGDEL.js");
|
|
136
|
-
SUGGET_WITHPAYLOADS: typeof import("@redis/search/dist/commands/SUGGET_WITHPAYLOADS.js");
|
|
137
|
-
sugGetWithPayloads: typeof import("@redis/search/dist/commands/SUGGET_WITHPAYLOADS.js");
|
|
138
|
-
SUGGET_WITHSCORES_WITHPAYLOADS: typeof import("@redis/search/dist/commands/SUGGET_WITHSCORES_WITHPAYLOADS.js");
|
|
139
|
-
sugGetWithScoresWithPayloads: typeof import("@redis/search/dist/commands/SUGGET_WITHSCORES_WITHPAYLOADS.js");
|
|
140
|
-
SUGGET_WITHSCORES: typeof import("@redis/search/dist/commands/SUGGET_WITHSCORES.js");
|
|
141
|
-
sugGetWithScores: typeof import("@redis/search/dist/commands/SUGGET_WITHSCORES.js");
|
|
142
|
-
SUGGET: typeof import("@redis/search/dist/commands/SUGGET.js");
|
|
143
|
-
sugGet: typeof import("@redis/search/dist/commands/SUGGET.js");
|
|
144
|
-
SUGLEN: typeof import("@redis/search/dist/commands/SUGLEN.js");
|
|
145
|
-
sugLen: typeof import("@redis/search/dist/commands/SUGLEN.js");
|
|
146
|
-
SYNDUMP: typeof import("@redis/search/dist/commands/SYNDUMP.js");
|
|
147
|
-
synDump: typeof import("@redis/search/dist/commands/SYNDUMP.js");
|
|
148
|
-
SYNUPDATE: typeof import("@redis/search/dist/commands/SYNUPDATE.js");
|
|
149
|
-
synUpdate: typeof import("@redis/search/dist/commands/SYNUPDATE.js");
|
|
150
|
-
TAGVALS: typeof import("@redis/search/dist/commands/TAGVALS.js");
|
|
151
|
-
tagVals: typeof import("@redis/search/dist/commands/TAGVALS.js");
|
|
152
|
-
};
|
|
153
|
-
ts: {
|
|
154
|
-
ADD: typeof import("@redis/time-series/dist/commands/ADD.js");
|
|
155
|
-
add: typeof import("@redis/time-series/dist/commands/ADD.js");
|
|
156
|
-
ALTER: typeof import("@redis/time-series/dist/commands/ALTER.js");
|
|
157
|
-
alter: typeof import("@redis/time-series/dist/commands/ALTER.js");
|
|
158
|
-
CREATE: typeof import("@redis/time-series/dist/commands/CREATE.js");
|
|
159
|
-
create: typeof import("@redis/time-series/dist/commands/CREATE.js");
|
|
160
|
-
CREATERULE: typeof import("@redis/time-series/dist/commands/CREATERULE.js");
|
|
161
|
-
createRule: typeof import("@redis/time-series/dist/commands/CREATERULE.js");
|
|
162
|
-
DECRBY: typeof import("@redis/time-series/dist/commands/DECRBY.js");
|
|
163
|
-
decrBy: typeof import("@redis/time-series/dist/commands/DECRBY.js");
|
|
164
|
-
DEL: typeof import("@redis/time-series/dist/commands/DEL.js");
|
|
165
|
-
del: typeof import("@redis/time-series/dist/commands/DEL.js");
|
|
166
|
-
DELETERULE: typeof import("@redis/time-series/dist/commands/DELETERULE.js");
|
|
167
|
-
deleteRule: typeof import("@redis/time-series/dist/commands/DELETERULE.js");
|
|
168
|
-
GET: typeof import("@redis/time-series/dist/commands/GET.js");
|
|
169
|
-
get: typeof import("@redis/time-series/dist/commands/GET.js");
|
|
170
|
-
INCRBY: typeof import("@redis/time-series/dist/commands/INCRBY.js");
|
|
171
|
-
incrBy: typeof import("@redis/time-series/dist/commands/INCRBY.js");
|
|
172
|
-
INFO_DEBUG: typeof import("@redis/time-series/dist/commands/INFO_DEBUG.js");
|
|
173
|
-
infoDebug: typeof import("@redis/time-series/dist/commands/INFO_DEBUG.js");
|
|
174
|
-
INFO: typeof import("@redis/time-series/dist/commands/INFO.js");
|
|
175
|
-
info: typeof import("@redis/time-series/dist/commands/INFO.js");
|
|
176
|
-
MADD: typeof import("@redis/time-series/dist/commands/MADD.js");
|
|
177
|
-
mAdd: typeof import("@redis/time-series/dist/commands/MADD.js");
|
|
178
|
-
MGET: typeof import("@redis/time-series/dist/commands/MGET.js");
|
|
179
|
-
mGet: typeof import("@redis/time-series/dist/commands/MGET.js");
|
|
180
|
-
MGET_WITHLABELS: typeof import("@redis/time-series/dist/commands/MGET_WITHLABELS.js");
|
|
181
|
-
mGetWithLabels: typeof import("@redis/time-series/dist/commands/MGET_WITHLABELS.js");
|
|
182
|
-
QUERYINDEX: typeof import("@redis/time-series/dist/commands/QUERYINDEX.js");
|
|
183
|
-
queryIndex: typeof import("@redis/time-series/dist/commands/QUERYINDEX.js");
|
|
184
|
-
RANGE: typeof import("@redis/time-series/dist/commands/RANGE.js");
|
|
185
|
-
range: typeof import("@redis/time-series/dist/commands/RANGE.js");
|
|
186
|
-
REVRANGE: typeof import("@redis/time-series/dist/commands/REVRANGE.js");
|
|
187
|
-
revRange: typeof import("@redis/time-series/dist/commands/REVRANGE.js");
|
|
188
|
-
MRANGE: typeof import("@redis/time-series/dist/commands/MRANGE.js");
|
|
189
|
-
mRange: typeof import("@redis/time-series/dist/commands/MRANGE.js");
|
|
190
|
-
MRANGE_WITHLABELS: typeof import("@redis/time-series/dist/commands/MRANGE_WITHLABELS.js");
|
|
191
|
-
mRangeWithLabels: typeof import("@redis/time-series/dist/commands/MRANGE_WITHLABELS.js");
|
|
192
|
-
MREVRANGE: typeof import("@redis/time-series/dist/commands/MREVRANGE.js");
|
|
193
|
-
mRevRange: typeof import("@redis/time-series/dist/commands/MREVRANGE.js");
|
|
194
|
-
MREVRANGE_WITHLABELS: typeof import("@redis/time-series/dist/commands/MREVRANGE_WITHLABELS.js");
|
|
195
|
-
mRevRangeWithLabels: typeof import("@redis/time-series/dist/commands/MREVRANGE_WITHLABELS.js");
|
|
196
|
-
};
|
|
197
|
-
bf: {
|
|
198
|
-
ADD: typeof import("@redis/bloom/dist/commands/bloom/ADD.js");
|
|
199
|
-
add: typeof import("@redis/bloom/dist/commands/bloom/ADD.js");
|
|
200
|
-
CARD: typeof import("@redis/bloom/dist/commands/bloom/CARD.js");
|
|
201
|
-
card: typeof import("@redis/bloom/dist/commands/bloom/CARD.js");
|
|
202
|
-
EXISTS: typeof import("@redis/bloom/dist/commands/bloom/EXISTS.js");
|
|
203
|
-
exists: typeof import("@redis/bloom/dist/commands/bloom/EXISTS.js");
|
|
204
|
-
INFO: typeof import("@redis/bloom/dist/commands/bloom/INFO.js");
|
|
205
|
-
info: typeof import("@redis/bloom/dist/commands/bloom/INFO.js");
|
|
206
|
-
INSERT: typeof import("@redis/bloom/dist/commands/bloom/INSERT.js");
|
|
207
|
-
insert: typeof import("@redis/bloom/dist/commands/bloom/INSERT.js");
|
|
208
|
-
LOADCHUNK: typeof import("@redis/bloom/dist/commands/bloom/LOADCHUNK.js");
|
|
209
|
-
loadChunk: typeof import("@redis/bloom/dist/commands/bloom/LOADCHUNK.js");
|
|
210
|
-
MADD: typeof import("@redis/bloom/dist/commands/bloom/MADD.js");
|
|
211
|
-
mAdd: typeof import("@redis/bloom/dist/commands/bloom/MADD.js");
|
|
212
|
-
MEXISTS: typeof import("@redis/bloom/dist/commands/bloom/MEXISTS.js");
|
|
213
|
-
mExists: typeof import("@redis/bloom/dist/commands/bloom/MEXISTS.js");
|
|
214
|
-
RESERVE: typeof import("@redis/bloom/dist/commands/bloom/RESERVE.js");
|
|
215
|
-
reserve: typeof import("@redis/bloom/dist/commands/bloom/RESERVE.js");
|
|
216
|
-
SCANDUMP: typeof import("@redis/bloom/dist/commands/bloom/SCANDUMP.js");
|
|
217
|
-
scanDump: typeof import("@redis/bloom/dist/commands/bloom/SCANDUMP.js");
|
|
218
|
-
};
|
|
219
|
-
cms: {
|
|
220
|
-
INCRBY: typeof import("@redis/bloom/dist/commands/count-min-sketch/INCRBY.js");
|
|
221
|
-
incrBy: typeof import("@redis/bloom/dist/commands/count-min-sketch/INCRBY.js");
|
|
222
|
-
INFO: typeof import("@redis/bloom/dist/commands/count-min-sketch/INFO.js");
|
|
223
|
-
info: typeof import("@redis/bloom/dist/commands/count-min-sketch/INFO.js");
|
|
224
|
-
INITBYDIM: typeof import("@redis/bloom/dist/commands/count-min-sketch/INITBYDIM.js");
|
|
225
|
-
initByDim: typeof import("@redis/bloom/dist/commands/count-min-sketch/INITBYDIM.js");
|
|
226
|
-
INITBYPROB: typeof import("@redis/bloom/dist/commands/count-min-sketch/INITBYPROB.js");
|
|
227
|
-
initByProb: typeof import("@redis/bloom/dist/commands/count-min-sketch/INITBYPROB.js");
|
|
228
|
-
MERGE: typeof import("@redis/bloom/dist/commands/count-min-sketch/MERGE.js");
|
|
229
|
-
merge: typeof import("@redis/bloom/dist/commands/count-min-sketch/MERGE.js");
|
|
230
|
-
QUERY: typeof import("@redis/bloom/dist/commands/count-min-sketch/QUERY.js");
|
|
231
|
-
query: typeof import("@redis/bloom/dist/commands/count-min-sketch/QUERY.js");
|
|
232
|
-
};
|
|
233
|
-
cf: {
|
|
234
|
-
ADD: typeof import("@redis/bloom/dist/commands/cuckoo/ADD.js");
|
|
235
|
-
add: typeof import("@redis/bloom/dist/commands/cuckoo/ADD.js");
|
|
236
|
-
ADDNX: typeof import("@redis/bloom/dist/commands/cuckoo/ADDNX.js");
|
|
237
|
-
addNX: typeof import("@redis/bloom/dist/commands/cuckoo/ADDNX.js");
|
|
238
|
-
COUNT: typeof import("@redis/bloom/dist/commands/cuckoo/COUNT.js");
|
|
239
|
-
count: typeof import("@redis/bloom/dist/commands/cuckoo/COUNT.js");
|
|
240
|
-
DEL: typeof import("@redis/bloom/dist/commands/cuckoo/DEL.js");
|
|
241
|
-
del: typeof import("@redis/bloom/dist/commands/cuckoo/DEL.js");
|
|
242
|
-
EXISTS: typeof import("@redis/bloom/dist/commands/cuckoo/EXISTS.js");
|
|
243
|
-
exists: typeof import("@redis/bloom/dist/commands/cuckoo/EXISTS.js");
|
|
244
|
-
INFO: typeof import("@redis/bloom/dist/commands/cuckoo/INFO.js");
|
|
245
|
-
info: typeof import("@redis/bloom/dist/commands/cuckoo/INFO.js");
|
|
246
|
-
INSERT: typeof import("@redis/bloom/dist/commands/cuckoo/INSERT.js");
|
|
247
|
-
insert: typeof import("@redis/bloom/dist/commands/cuckoo/INSERT.js");
|
|
248
|
-
INSERTNX: typeof import("@redis/bloom/dist/commands/cuckoo/INSERTNX.js");
|
|
249
|
-
insertNX: typeof import("@redis/bloom/dist/commands/cuckoo/INSERTNX.js");
|
|
250
|
-
LOADCHUNK: typeof import("@redis/bloom/dist/commands/cuckoo/LOADCHUNK.js");
|
|
251
|
-
loadChunk: typeof import("@redis/bloom/dist/commands/cuckoo/LOADCHUNK.js");
|
|
252
|
-
RESERVE: typeof import("@redis/bloom/dist/commands/cuckoo/RESERVE.js");
|
|
253
|
-
reserve: typeof import("@redis/bloom/dist/commands/cuckoo/RESERVE.js");
|
|
254
|
-
SCANDUMP: typeof import("@redis/bloom/dist/commands/cuckoo/SCANDUMP.js");
|
|
255
|
-
scanDump: typeof import("@redis/bloom/dist/commands/cuckoo/SCANDUMP.js");
|
|
256
|
-
};
|
|
257
|
-
tDigest: {
|
|
258
|
-
ADD: typeof import("@redis/bloom/dist/commands/t-digest/ADD.js");
|
|
259
|
-
add: typeof import("@redis/bloom/dist/commands/t-digest/ADD.js");
|
|
260
|
-
BYRANK: typeof import("@redis/bloom/dist/commands/t-digest/BYRANK.js");
|
|
261
|
-
byRank: typeof import("@redis/bloom/dist/commands/t-digest/BYRANK.js");
|
|
262
|
-
BYREVRANK: typeof import("@redis/bloom/dist/commands/t-digest/BYREVRANK.js");
|
|
263
|
-
byRevRank: typeof import("@redis/bloom/dist/commands/t-digest/BYREVRANK.js");
|
|
264
|
-
CDF: typeof import("@redis/bloom/dist/commands/t-digest/CDF.js");
|
|
265
|
-
cdf: typeof import("@redis/bloom/dist/commands/t-digest/CDF.js");
|
|
266
|
-
CREATE: typeof import("@redis/bloom/dist/commands/t-digest/CREATE.js");
|
|
267
|
-
create: typeof import("@redis/bloom/dist/commands/t-digest/CREATE.js");
|
|
268
|
-
INFO: typeof import("@redis/bloom/dist/commands/t-digest/INFO.js");
|
|
269
|
-
info: typeof import("@redis/bloom/dist/commands/t-digest/INFO.js");
|
|
270
|
-
MAX: typeof import("@redis/bloom/dist/commands/t-digest/MAX.js");
|
|
271
|
-
max: typeof import("@redis/bloom/dist/commands/t-digest/MAX.js");
|
|
272
|
-
MERGE: typeof import("@redis/bloom/dist/commands/t-digest/MERGE.js");
|
|
273
|
-
merge: typeof import("@redis/bloom/dist/commands/t-digest/MERGE.js");
|
|
274
|
-
MIN: typeof import("@redis/bloom/dist/commands/t-digest/MIN.js");
|
|
275
|
-
min: typeof import("@redis/bloom/dist/commands/t-digest/MIN.js");
|
|
276
|
-
QUANTILE: typeof import("@redis/bloom/dist/commands/t-digest/QUANTILE.js");
|
|
277
|
-
quantile: typeof import("@redis/bloom/dist/commands/t-digest/QUANTILE.js");
|
|
278
|
-
RANK: typeof import("@redis/bloom/dist/commands/t-digest/RANK.js");
|
|
279
|
-
rank: typeof import("@redis/bloom/dist/commands/t-digest/RANK.js");
|
|
280
|
-
RESET: typeof import("@redis/bloom/dist/commands/t-digest/RESET.js");
|
|
281
|
-
reset: typeof import("@redis/bloom/dist/commands/t-digest/RESET.js");
|
|
282
|
-
REVRANK: typeof import("@redis/bloom/dist/commands/t-digest/REVRANK.js");
|
|
283
|
-
revRank: typeof import("@redis/bloom/dist/commands/t-digest/REVRANK.js");
|
|
284
|
-
TRIMMED_MEAN: typeof import("@redis/bloom/dist/commands/t-digest/TRIMMED_MEAN.js");
|
|
285
|
-
trimmedMean: typeof import("@redis/bloom/dist/commands/t-digest/TRIMMED_MEAN.js");
|
|
286
|
-
};
|
|
287
|
-
topK: {
|
|
288
|
-
ADD: typeof import("@redis/bloom/dist/commands/top-k/ADD.js");
|
|
289
|
-
add: typeof import("@redis/bloom/dist/commands/top-k/ADD.js");
|
|
290
|
-
COUNT: typeof import("@redis/bloom/dist/commands/top-k/COUNT.js");
|
|
291
|
-
count: typeof import("@redis/bloom/dist/commands/top-k/COUNT.js");
|
|
292
|
-
INCRBY: typeof import("@redis/bloom/dist/commands/top-k/INCRBY.js");
|
|
293
|
-
incrBy: typeof import("@redis/bloom/dist/commands/top-k/INCRBY.js");
|
|
294
|
-
INFO: typeof import("@redis/bloom/dist/commands/top-k/INFO.js");
|
|
295
|
-
info: typeof import("@redis/bloom/dist/commands/top-k/INFO.js");
|
|
296
|
-
LIST_WITHCOUNT: typeof import("@redis/bloom/dist/commands/top-k/LIST_WITHCOUNT.js");
|
|
297
|
-
listWithCount: typeof import("@redis/bloom/dist/commands/top-k/LIST_WITHCOUNT.js");
|
|
298
|
-
LIST: typeof import("@redis/bloom/dist/commands/top-k/LIST.js");
|
|
299
|
-
list: typeof import("@redis/bloom/dist/commands/top-k/LIST.js");
|
|
300
|
-
QUERY: typeof import("@redis/bloom/dist/commands/top-k/QUERY.js");
|
|
301
|
-
query: typeof import("@redis/bloom/dist/commands/top-k/QUERY.js");
|
|
302
|
-
RESERVE: typeof import("@redis/bloom/dist/commands/top-k/RESERVE.js");
|
|
303
|
-
reserve: typeof import("@redis/bloom/dist/commands/top-k/RESERVE.js");
|
|
304
|
-
};
|
|
305
|
-
} & import("redis").RedisModules, import("redis").RedisFunctions, import("redis").RedisScripts>;
|
|
14
|
+
export type MilkioRedis<RedisT = any> = {
|
|
15
|
+
redis: RedisT;
|
|
306
16
|
useCache: <T>(key: string, options?: MilkioRedisCacheOptions<T>) => {
|
|
307
|
-
set: (value: T, expireMs: number) => Promise<T>;
|
|
17
|
+
set: (value: T, expireMs: number | null) => Promise<T>;
|
|
308
18
|
get: () => Promise<T | undefined>;
|
|
309
|
-
pull: () => Promise<
|
|
19
|
+
pull: () => Promise<T | undefined>;
|
|
310
20
|
has: () => Promise<boolean>;
|
|
311
21
|
del: () => Promise<void>;
|
|
312
22
|
};
|
|
313
|
-
useFetch: <
|
|
23
|
+
useFetch: <T>(key: string, options: MilkioRedisFetchOptions<T>) => {
|
|
314
24
|
has: () => Promise<boolean>;
|
|
315
25
|
del: () => Promise<void>;
|
|
316
|
-
fetch: () => Promise<
|
|
26
|
+
fetch: () => Promise<T>;
|
|
317
27
|
refresh: () => Promise<void>;
|
|
318
28
|
};
|
|
319
29
|
useCount: (key: string) => {
|
|
320
30
|
get: () => Promise<number>;
|
|
321
|
-
add: (amount: number, expireMs?: number) => Promise<number>;
|
|
31
|
+
add: (amount: number, expireMs?: number | null) => Promise<number>;
|
|
322
32
|
sub: (amount: number) => Promise<number>;
|
|
323
33
|
};
|
|
324
34
|
useClockIn: (key: string, cleanDate: Date) => {
|
|
@@ -330,5 +40,11 @@ export declare function createRedis<Options extends RedisClientOptions>(options:
|
|
|
330
40
|
count: () => Promise<number>;
|
|
331
41
|
clean: () => Promise<void>;
|
|
332
42
|
};
|
|
333
|
-
}
|
|
334
|
-
export
|
|
43
|
+
};
|
|
44
|
+
export declare function createRedis<RedisT extends {
|
|
45
|
+
PSETEX: any;
|
|
46
|
+
SET: any;
|
|
47
|
+
[others: string | number | symbol]: any;
|
|
48
|
+
}>(redisClient: RedisT): Promise<MilkioRedis<RedisT>>;
|
|
49
|
+
export declare function reviveJSONParse<T>(json: T): T;
|
|
50
|
+
export type Redis = MilkioRedis;
|