lakutata 2.0.39 → 2.0.41
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/com/cacher.cjs +17 -19
- package/com/cacher.d.ts +16 -6
- package/com/cacher.mjs +1 -1
- package/package.json +1 -1
- package/src/components/cacher/Cacher.cjs +195 -178
- package/src/components/cacher/Cacher.mjs +182 -165
- package/src/components/cacher/interfaces/CacherOptions.cjs +1 -0
- package/src/components/cacher/interfaces/CacherOptions.mjs +1 -0
- package/vendor/Package.18.cjs +184 -195
- package/vendor/Package.18.mjs +176 -187
- package/src/components/cacher/options/CacherOptions.cjs +0 -95
- package/src/components/cacher/options/CacherOptions.mjs +0 -89
package/com/cacher.cjs
CHANGED
|
@@ -8,25 +8,25 @@ require("../vendor/Package.4.cjs");
|
|
|
8
8
|
|
|
9
9
|
const e = require("../src/components/cacher/Cacher.cjs");
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
require("../src/components/cacher/interfaces/CacherOptions.cjs");
|
|
12
12
|
|
|
13
|
-
const
|
|
13
|
+
const r = require("../src/components/cacher/options/FileCacheOptions.cjs");
|
|
14
14
|
|
|
15
|
-
const
|
|
15
|
+
const c = require("../src/components/cacher/options/MemcacheCacheOptions.cjs");
|
|
16
16
|
|
|
17
|
-
const
|
|
17
|
+
const s = require("../src/components/cacher/options/MongoCacheOptions.cjs");
|
|
18
18
|
|
|
19
|
-
const
|
|
19
|
+
const i = require("../src/components/cacher/options/MysqlCacheOptions.cjs");
|
|
20
20
|
|
|
21
|
-
const
|
|
21
|
+
const o = require("../src/components/cacher/options/PostgresCacheOptions.cjs");
|
|
22
22
|
|
|
23
|
-
const
|
|
23
|
+
const t = require("../src/components/cacher/options/RedisCacheOptions.cjs");
|
|
24
24
|
|
|
25
|
-
const
|
|
25
|
+
const n = require("../src/components/cacher/options/SqliteCacheOptions.cjs");
|
|
26
26
|
|
|
27
27
|
require("../src/components/cacher/types/CacheStoreOptions.cjs");
|
|
28
28
|
|
|
29
|
-
const
|
|
29
|
+
const a = require("../src/components/cacher/exceptions/CacheDriverNotFoundException.cjs");
|
|
30
30
|
|
|
31
31
|
require("../vendor/Package.5.cjs");
|
|
32
32
|
|
|
@@ -216,20 +216,18 @@ exports.BuildCacherOptions = e.BuildCacherOptions;
|
|
|
216
216
|
|
|
217
217
|
exports.Cacher = e.Cacher;
|
|
218
218
|
|
|
219
|
-
exports.
|
|
219
|
+
exports.FileCacheOptions = r.FileCacheOptions;
|
|
220
220
|
|
|
221
|
-
exports.
|
|
221
|
+
exports.MemcacheCacheOptions = c.MemcacheCacheOptions;
|
|
222
222
|
|
|
223
|
-
exports.
|
|
223
|
+
exports.MongoCacheOptions = s.MongoCacheOptions;
|
|
224
224
|
|
|
225
|
-
exports.
|
|
225
|
+
exports.MysqlCacheOptions = i.MysqlCacheOptions;
|
|
226
226
|
|
|
227
|
-
exports.
|
|
227
|
+
exports.PostgresCacheOptions = o.PostgresCacheOptions;
|
|
228
228
|
|
|
229
|
-
exports.
|
|
229
|
+
exports.RedisCacheOptions = t.RedisCacheOptions;
|
|
230
230
|
|
|
231
|
-
exports.
|
|
231
|
+
exports.SqliteCacheOptions = n.SqliteCacheOptions;
|
|
232
232
|
|
|
233
|
-
exports.
|
|
234
|
-
|
|
235
|
-
exports.CacheDriverNotFoundException = u.CacheDriverNotFoundException;
|
|
233
|
+
exports.CacheDriverNotFoundException = a.CacheDriverNotFoundException;
|
package/com/cacher.d.ts
CHANGED
|
@@ -460,7 +460,7 @@ declare class MemcacheCacheOptions extends DTO {
|
|
|
460
460
|
|
|
461
461
|
type CacheStoreOptions = FileCacheOptions | RedisCacheOptions | MemcacheCacheOptions | MongoCacheOptions | SqliteCacheOptions | PostgresCacheOptions | MysqlCacheOptions;
|
|
462
462
|
|
|
463
|
-
|
|
463
|
+
interface CacherOptions {
|
|
464
464
|
stores?: CacheStoreOptions[] | CacheStoreOptions;
|
|
465
465
|
ttl?: number;
|
|
466
466
|
refreshThreshold?: number;
|
|
@@ -471,7 +471,12 @@ declare class CacherOptions extends DTO {
|
|
|
471
471
|
|
|
472
472
|
declare const BuildCacherOptions: (options?: CacherOptions) => {
|
|
473
473
|
class: typeof Cacher;
|
|
474
|
-
|
|
474
|
+
stores?: CacheStoreOptions[] | CacheStoreOptions;
|
|
475
|
+
ttl?: number;
|
|
476
|
+
refreshThreshold?: number;
|
|
477
|
+
refreshAllStores?: boolean;
|
|
478
|
+
nonBlocking?: boolean;
|
|
479
|
+
cacheId?: string;
|
|
475
480
|
};
|
|
476
481
|
type MultipleSetInput = {
|
|
477
482
|
key: string;
|
|
@@ -493,7 +498,12 @@ type OnRefreshEventData = {
|
|
|
493
498
|
error?: Error;
|
|
494
499
|
};
|
|
495
500
|
declare class Cacher extends Component {
|
|
496
|
-
protected readonly
|
|
501
|
+
protected readonly stores?: CacheStoreOptions[] | CacheStoreOptions;
|
|
502
|
+
protected readonly ttl?: number;
|
|
503
|
+
protected readonly refreshThreshold?: number;
|
|
504
|
+
protected readonly refreshAllStores?: boolean;
|
|
505
|
+
protected readonly nonBlocking?: boolean;
|
|
506
|
+
protected readonly cacheId?: string;
|
|
497
507
|
protected cache: Cache;
|
|
498
508
|
protected init(): Promise<void>;
|
|
499
509
|
protected destroy(): Promise<void>;
|
|
@@ -501,7 +511,7 @@ declare class Cacher extends Component {
|
|
|
501
511
|
multipleSet(options: MultipleSetInput[]): Promise<MultipleSetInput[]>;
|
|
502
512
|
get<T = any>(key: string): Promise<T>;
|
|
503
513
|
multipleGet(keys: string[]): Promise<any[]>;
|
|
504
|
-
|
|
514
|
+
getTTL(key: string): Promise<number>;
|
|
505
515
|
del(key: string): Promise<boolean>;
|
|
506
516
|
multipleDel(keys: string[]): Promise<boolean>;
|
|
507
517
|
clear(): Promise<boolean>;
|
|
@@ -515,5 +525,5 @@ declare class CacheDriverNotFoundException extends Exception {
|
|
|
515
525
|
errno: string | number;
|
|
516
526
|
}
|
|
517
527
|
|
|
518
|
-
export { BuildCacherOptions, CacheDriverNotFoundException, Cacher,
|
|
519
|
-
export type { CacheStoreOptions, MultipleSetInput, OnDelEventData, OnRefreshEventData, OnSetEventData };
|
|
528
|
+
export { BuildCacherOptions, CacheDriverNotFoundException, Cacher, FileCacheOptions, MemcacheCacheOptions, MongoCacheOptions, MysqlCacheOptions, PostgresCacheOptions, RedisCacheOptions, SqliteCacheOptions };
|
|
529
|
+
export type { CacheStoreOptions, CacherOptions, MultipleSetInput, OnDelEventData, OnRefreshEventData, OnSetEventData };
|
package/com/cacher.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import "../vendor/Package.4.mjs";
|
|
|
2
2
|
|
|
3
3
|
export { BuildCacherOptions, Cacher } from "../src/components/cacher/Cacher.mjs";
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
import "../src/components/cacher/interfaces/CacherOptions.mjs";
|
|
6
6
|
|
|
7
7
|
export { FileCacheOptions } from "../src/components/cacher/options/FileCacheOptions.mjs";
|
|
8
8
|
|