koatty_store 1.6.2 → 1.8.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/.rollup.config.js CHANGED
@@ -3,27 +3,44 @@
3
3
  * @Usage:
4
4
  * @Author: richen
5
5
  * @Date: 2021-12-17 10:20:44
6
- * @LastEditTime: 2023-02-18 23:21:06
6
+ * @LastEditTime: 2024-11-04 22:04:45
7
7
  */
8
+ import commonjs from '@rollup/plugin-commonjs';
8
9
  import json from "@rollup/plugin-json";
10
+ import resolve from '@rollup/plugin-node-resolve';
11
+ import { builtinModules } from 'module';
12
+ import del from "rollup-plugin-delete";
9
13
  import typescript from 'rollup-plugin-typescript2';
10
14
  // import babel from '@rollup/plugin-babel';
15
+ const pkg = require('./package.json');
11
16
 
12
17
  export default [
13
18
  {
14
19
  input: './src/index.ts',
15
- output: [{
16
- format: 'cjs',
17
- file: './dist/index.js',
18
- banner: require('./scripts/copyright')
19
- }],
20
+ output: [
21
+ {
22
+ format: 'cjs',
23
+ file: './dist/index.js',
24
+ banner: require('./scripts/copyright'),
25
+ },
26
+ {
27
+ format: 'es',
28
+ file: './dist/index.mjs',
29
+ banner: require('./scripts/copyright'),
30
+ },
31
+ ],
20
32
  plugins: [
33
+ del({ targets: ["dist/*", "temp/*", "docs/api"] }),
21
34
  // babel({
22
35
  // babelHelpers: "runtime",
23
36
  // configFile: './babel.config.js',
24
37
  // exclude: 'node_modules/**',
25
38
  // }),
26
39
  json(),
40
+ resolve({
41
+ preferBuiltins: true, // 优先选择内置模块
42
+ }),
43
+ commonjs(),
27
44
  typescript({
28
45
  tsconfigOverride: {
29
46
  compilerOptions: {
@@ -33,31 +50,11 @@ export default [
33
50
  }
34
51
  }
35
52
  })
36
- ]
53
+ ],
54
+ external: [
55
+ ...builtinModules, // 排除 Node.js 内置模块
56
+ ...Object.keys(pkg.dependencies || {}), // 排除 package.json 中的外部依赖
57
+ ],
37
58
  },
38
- {
39
- input: './src/index.ts',
40
- output: [{
41
- format: 'es',
42
- file: './dist/index.mjs',
43
- banner: require('./scripts/copyright')
44
- }],
45
- plugins: [
46
- // babel({
47
- // babelHelpers: "runtime",
48
- // configFile: './babel.config.js',
49
- // exclude: 'node_modules/**',
50
- // }),
51
- json(),
52
- typescript({
53
- tsconfigOverride: {
54
- compilerOptions: {
55
- declaration: false,
56
- declarationMap: false,
57
- module: "ESNext"
58
- }
59
- }
60
- })
61
- ]
62
- }
59
+
63
60
  ]
package/CHANGELOG.md CHANGED
@@ -2,6 +2,25 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ## [1.8.0](https://github.com/koatty/koatty_store/compare/v1.7.0...v1.8.0) (2025-06-09)
6
+
7
+
8
+ ### Features
9
+
10
+ * enhance CacheStoreInterface with extended command support, memory store optimization options ([05c7513](https://github.com/koatty/koatty_store/commit/05c75137e45902570620a86714a260ae1f21aee9))
11
+ * enhance MemoryCache eviction event with additional insert event and detailed reason ([d1537f7](https://github.com/koatty/koatty_store/commit/d1537f70f2c8ba3aed676296575fde7f92caf9d4))
12
+ * implement comprehensive CacheStore with memory/redis support ([d10f36d](https://github.com/koatty/koatty_store/commit/d10f36d362ebb416755a6e5d10591c8d582d356b))
13
+ * implement LRU cache ([a426b4b](https://github.com/koatty/koatty_store/commit/a426b4b93e8a0e7572972e7e823f24c6f9a9e3f0))
14
+ * implement multi-instance CacheStore management with configurable keys and cleanup methods ([7fdc773](https://github.com/koatty/koatty_store/commit/7fdc77389f2e37d18659444cac82bdfc5b9cd358))
15
+ * improve Redis connection handling with reconnection logic and pool configuration ([79b2836](https://github.com/koatty/koatty_store/commit/79b2836ba3dab7fef7a094d69697e1d7d52d1e90))
16
+
17
+
18
+ ### Bug Fixes
19
+
20
+ * ensure hash entries are not prematurely evicted when timeout is not specified ([961db57](https://github.com/koatty/koatty_store/commit/961db5761dd0d1ecf1e15da35ccc1e74d047d6e7))
21
+
22
+ ## [1.7.0](https://github.com/koatty/koatty_store/compare/v1.6.2...v1.7.0) (2024-11-07)
23
+
5
24
  ### [1.6.2](https://github.com/koatty/koatty_store/compare/v1.6.1...v1.6.2) (2023-12-20)
6
25
 
7
26
  ### [1.6.1](https://github.com/koatty/koatty_store/compare/v1.6.0...v1.6.1) (2023-07-28)