@dbx-tools/cache 0.9.129 → 0.9.132
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 +11 -7
- package/index.ts +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +2 -2
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -1,11 +1,8 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @dbx-tools/cache
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
project-scoped portable disk file without blocking foreground writes. Additional
|
|
7
|
-
Keyv-compatible levels can be supplied in read order. Pending persistence is
|
|
8
|
-
tracked and can be drained during application shutdown.
|
|
3
|
+
Cache Node.js and Bun values in bounded memory with optional project-scoped
|
|
4
|
+
disk or Keyv-compatible persistence. Foreground writes don't wait for
|
|
5
|
+
persistence, and shutdown can drain tracked writes.
|
|
9
6
|
|
|
10
7
|
## Cache project data
|
|
11
8
|
|
|
@@ -40,3 +37,10 @@ await closeCache(cache);
|
|
|
40
37
|
Pass ordered Keyv-compatible `levels` to `createCache` when an application needs
|
|
41
38
|
custom persistence. The package does not depend on AppKit;
|
|
42
39
|
`@dbx-tools/appkit` adapts it to AppKit's storage contract.
|
|
40
|
+
|
|
41
|
+
## Limits
|
|
42
|
+
|
|
43
|
+
The memory level is process-local and isn't a cross-replica coordination
|
|
44
|
+
mechanism. Call `closeCache()` during shutdown when later levels must receive
|
|
45
|
+
pending writes. Use a shared Keyv-compatible level or an owning framework's
|
|
46
|
+
distributed cache when replicas must read the same persisted values.
|
package/index.ts
CHANGED
|
@@ -3,6 +3,6 @@
|
|
|
3
3
|
// Hand edits are overwritten on the next watch; this file is read-only.
|
|
4
4
|
|
|
5
5
|
export const PACKAGE_IDENTIFIER = "@dbx-tools/cache";
|
|
6
|
-
export const PACKAGE_VERSION = "0.9.
|
|
6
|
+
export const PACKAGE_VERSION = "0.9.132";
|
|
7
7
|
export * as cache from "./src/cache.ts";
|
|
8
8
|
export type { CacheLevel, CacheOptions, ProjectCacheOptions, GetOrSetOptions } from "./src/cache.ts";
|
package/lib/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export declare const PACKAGE_IDENTIFIER = "@dbx-tools/cache";
|
|
2
|
-
export declare const PACKAGE_VERSION = "0.9.
|
|
2
|
+
export declare const PACKAGE_VERSION = "0.9.132";
|
|
3
3
|
export * as cache from "./src/cache.ts";
|
|
4
4
|
export type { CacheLevel, CacheOptions, ProjectCacheOptions, GetOrSetOptions } from "./src/cache.ts";
|
package/lib/index.js
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
// Regenerated from the exporting modules in ./src.
|
|
3
3
|
// Hand edits are overwritten on the next watch; this file is read-only.
|
|
4
4
|
export const PACKAGE_IDENTIFIER = "@dbx-tools/cache";
|
|
5
|
-
export const PACKAGE_VERSION = "0.9.
|
|
5
|
+
export const PACKAGE_VERSION = "0.9.132";
|
|
6
6
|
export * as cache from "./src/cache.js";
|
|
7
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
7
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSwyQ0FBMkM7QUFDM0MsbURBQW1EO0FBQ25ELHdFQUF3RTtBQUV4RSxNQUFNLENBQUMsTUFBTSxrQkFBa0IsR0FBRyxrQkFBa0IsQ0FBQztBQUNyRCxNQUFNLENBQUMsTUFBTSxlQUFlLEdBQUcsU0FBUyxDQUFDO0FBQ3pDLE9BQU8sS0FBSyxLQUFLLE1BQU0sZ0JBQWdCLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvLyBHRU5FUkFURUQgYnkgcHJvamVuIHdhdGNoIC0gRE8gTk9UIEVESVQuXG4vLyBSZWdlbmVyYXRlZCBmcm9tIHRoZSBleHBvcnRpbmcgbW9kdWxlcyBpbiAuL3NyYy5cbi8vIEhhbmQgZWRpdHMgYXJlIG92ZXJ3cml0dGVuIG9uIHRoZSBuZXh0IHdhdGNoOyB0aGlzIGZpbGUgaXMgcmVhZC1vbmx5LlxuXG5leHBvcnQgY29uc3QgUEFDS0FHRV9JREVOVElGSUVSID0gXCJAZGJ4LXRvb2xzL2NhY2hlXCI7XG5leHBvcnQgY29uc3QgUEFDS0FHRV9WRVJTSU9OID0gXCIwLjkuMTMyXCI7XG5leHBvcnQgKiBhcyBjYWNoZSBmcm9tIFwiLi9zcmMvY2FjaGUudHNcIjtcbmV4cG9ydCB0eXBlIHsgQ2FjaGVMZXZlbCwgQ2FjaGVPcHRpb25zLCBQcm9qZWN0Q2FjaGVPcHRpb25zLCBHZXRPclNldE9wdGlvbnMgfSBmcm9tIFwiLi9zcmMvY2FjaGUudHNcIjtcbiJdfQ==
|
package/package.json
CHANGED
|
@@ -24,8 +24,8 @@
|
|
|
24
24
|
"vitest": "3.2.4"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@dbx-tools/core": "^0.9.
|
|
28
|
-
"@dbx-tools/shared-core": "^0.9.
|
|
27
|
+
"@dbx-tools/core": "^0.9.132",
|
|
28
|
+
"@dbx-tools/shared-core": "^0.9.132",
|
|
29
29
|
"cacheable": "2.5.0",
|
|
30
30
|
"env-paths": "^4.0.0",
|
|
31
31
|
"keyv-file": "5.3.5"
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"./package.json": "./package.json"
|
|
53
53
|
}
|
|
54
54
|
},
|
|
55
|
-
"version": "0.9.
|
|
55
|
+
"version": "0.9.132",
|
|
56
56
|
"types": "./lib/index.d.ts",
|
|
57
57
|
"dbxToolsConfig": {
|
|
58
58
|
"tags": [
|