@eggjs/logrotator 5.0.0-beta.19 → 5.0.0-beta.20
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/dist/agent.d.ts +1 -1
- package/dist/agent.js +1 -1
- package/dist/app/extend/agent.d.ts +1 -1
- package/dist/app/extend/agent.js +1 -1
- package/dist/app/extend/application.d.ts +2 -7
- package/dist/app/extend/application.js +2 -5
- package/dist/app/schedule/clean_log.js +1 -1
- package/dist/app/schedule/rotate_by_file.js +3 -1
- package/dist/app/schedule/rotate_by_hour.js +2 -1
- package/dist/app/schedule/rotate_by_size.js +2 -1
- package/dist/app.d.ts +1 -1
- package/dist/app.js +1 -1
- package/dist/application-DLlqYOTH.d.ts +8 -0
- package/dist/application-DUxqk1cL.js +7 -0
- package/dist/boot-Fk-0g48D.js +16 -0
- package/dist/boot-GzaTgWud.d.ts +10 -0
- package/dist/boot.d.ts +1 -9
- package/dist/boot.js +1 -14
- package/dist/config/config.default.d.ts +1 -61
- package/dist/config/config.default.js +1 -13
- package/dist/config.default-CnLV2bGK.d.ts +62 -0
- package/dist/config.default-CvMzfv2b.js +15 -0
- package/dist/day_rotator-DHd2Parx.js +64 -0
- package/dist/hour_rotator-JmysNFky.js +38 -0
- package/dist/index.d.ts +4 -1
- package/dist/index.js +4 -3
- package/dist/lib/day_rotator.d.ts +1 -1
- package/dist/lib/day_rotator.js +3 -62
- package/dist/lib/hour_rotator.d.ts +1 -1
- package/dist/lib/hour_rotator.js +2 -36
- package/dist/lib/rotator.d.ts +1 -19
- package/dist/lib/rotator.js +1 -54
- package/dist/lib/size_rotator.d.ts +1 -1
- package/dist/lib/size_rotator.js +2 -59
- package/dist/lib/utils.js +1 -13
- package/dist/rotator-BjJMXyaY.d.ts +20 -0
- package/dist/rotator-CRROE_AN.js +56 -0
- package/dist/size_rotator-B94wnaTP.js +61 -0
- package/dist/types-CQtQr8gw.js +1 -0
- package/dist/types-RmfrK2ke.d.ts +19 -0
- package/dist/types.d.ts +3 -19
- package/dist/types.js +2 -0
- package/dist/utils-Br9jwJMb.js +15 -0
- package/package.json +5 -5
package/dist/agent.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Boot } from "./boot.js";
|
|
1
|
+
import { Boot } from "./boot-GzaTgWud.js";
|
|
2
2
|
export { Boot as default };
|
package/dist/agent.js
CHANGED
package/dist/app/extend/agent.js
CHANGED
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
//#region src/app/extend/application.d.ts
|
|
4
|
-
declare const _default: {
|
|
5
|
-
LogRotator: typeof LogRotator;
|
|
6
|
-
};
|
|
7
|
-
//#endregion
|
|
1
|
+
import "../../rotator-BjJMXyaY.js";
|
|
2
|
+
import { _default } from "../../application-DLlqYOTH.js";
|
|
8
3
|
export { _default as default };
|
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import "../../rotator-CRROE_AN.js";
|
|
2
|
+
import { application_default } from "../../application-DUxqk1cL.js";
|
|
2
3
|
|
|
3
|
-
//#region src/app/extend/application.ts
|
|
4
|
-
var application_default = { LogRotator };
|
|
5
|
-
|
|
6
|
-
//#endregion
|
|
7
4
|
export { application_default as default };
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import
|
|
1
|
+
import "../../rotator-CRROE_AN.js";
|
|
2
|
+
import "../../utils-Br9jwJMb.js";
|
|
3
|
+
import { DayRotator } from "../../day_rotator-DHd2Parx.js";
|
|
2
4
|
|
|
3
5
|
//#region src/app/schedule/rotate_by_file.ts
|
|
4
6
|
var rotate_by_file_default = (app) => {
|
package/dist/app.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Boot } from "./boot.js";
|
|
1
|
+
import { Boot } from "./boot-GzaTgWud.js";
|
|
2
2
|
export { Boot as default };
|
package/dist/app.js
CHANGED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
//#region src/boot.ts
|
|
2
|
+
var Boot = class {
|
|
3
|
+
app;
|
|
4
|
+
constructor(app) {
|
|
5
|
+
this.app = app;
|
|
6
|
+
}
|
|
7
|
+
async didLoad() {
|
|
8
|
+
this.app.messenger.on("log-reload", () => {
|
|
9
|
+
this.app.loggers.reload();
|
|
10
|
+
this.app.coreLogger.info("[@eggjs/logrotator] %s logger reload: got log-reload message", this.app.type);
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
//#endregion
|
|
16
|
+
export { Boot };
|
package/dist/boot.d.ts
CHANGED
|
@@ -1,10 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
//#region src/boot.d.ts
|
|
4
|
-
declare class Boot implements ILifecycleBoot {
|
|
5
|
-
private readonly app;
|
|
6
|
-
constructor(app: Application);
|
|
7
|
-
didLoad(): Promise<void>;
|
|
8
|
-
}
|
|
9
|
-
//#endregion
|
|
1
|
+
import { Boot } from "./boot-GzaTgWud.js";
|
|
10
2
|
export { Boot };
|
package/dist/boot.js
CHANGED
|
@@ -1,16 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
var Boot = class {
|
|
3
|
-
app;
|
|
4
|
-
constructor(app) {
|
|
5
|
-
this.app = app;
|
|
6
|
-
}
|
|
7
|
-
async didLoad() {
|
|
8
|
-
this.app.messenger.on("log-reload", () => {
|
|
9
|
-
this.app.loggers.reload();
|
|
10
|
-
this.app.coreLogger.info("[@eggjs/logrotator] %s logger reload: got log-reload message", this.app.type);
|
|
11
|
-
});
|
|
12
|
-
}
|
|
13
|
-
};
|
|
1
|
+
import { Boot } from "./boot-Fk-0g48D.js";
|
|
14
2
|
|
|
15
|
-
//#endregion
|
|
16
3
|
export { Boot };
|
|
@@ -1,62 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
interface LogrotatorConfig {
|
|
3
|
-
/**
|
|
4
|
-
* Disable rotate by day
|
|
5
|
-
*
|
|
6
|
-
* Default: `false`
|
|
7
|
-
*/
|
|
8
|
-
disableRotateByDay: boolean;
|
|
9
|
-
/**
|
|
10
|
-
* List of files that will be rotated by hour
|
|
11
|
-
*
|
|
12
|
-
* Default: `null`
|
|
13
|
-
*/
|
|
14
|
-
filesRotateByHour: string[] | null;
|
|
15
|
-
/**
|
|
16
|
-
* Hour delimiter
|
|
17
|
-
*
|
|
18
|
-
* Default: `-`
|
|
19
|
-
*/
|
|
20
|
-
hourDelimiter: string;
|
|
21
|
-
/**
|
|
22
|
-
* List of files that will be rotated by size
|
|
23
|
-
*
|
|
24
|
-
* Default: `null`
|
|
25
|
-
*/
|
|
26
|
-
filesRotateBySize: string[] | null;
|
|
27
|
-
/**
|
|
28
|
-
* Max file size to judge if any file need rotate
|
|
29
|
-
*
|
|
30
|
-
* Default: `50 * 1024 * 1024`
|
|
31
|
-
*/
|
|
32
|
-
maxFileSize: number;
|
|
33
|
-
/**
|
|
34
|
-
* Max files to keep
|
|
35
|
-
*
|
|
36
|
-
* Default: `10`
|
|
37
|
-
*/
|
|
38
|
-
maxFiles: number;
|
|
39
|
-
/**
|
|
40
|
-
* Time interval to judge if any file need rotate
|
|
41
|
-
*
|
|
42
|
-
* Default: `60000`
|
|
43
|
-
*/
|
|
44
|
-
rotateDuration: number;
|
|
45
|
-
/**
|
|
46
|
-
* Max days to keep log files, set `0` to keep all logs.
|
|
47
|
-
*
|
|
48
|
-
* Default: `31`
|
|
49
|
-
*/
|
|
50
|
-
maxDays: number;
|
|
51
|
-
/**
|
|
52
|
-
* Enable gzip compression for rotated files
|
|
53
|
-
*
|
|
54
|
-
* Default: `false`
|
|
55
|
-
*/
|
|
56
|
-
gzip: boolean;
|
|
57
|
-
}
|
|
58
|
-
declare const _default: {
|
|
59
|
-
logrotator: LogrotatorConfig;
|
|
60
|
-
};
|
|
61
|
-
//#endregion
|
|
1
|
+
import { LogrotatorConfig, _default } from "../config.default-CnLV2bGK.js";
|
|
62
2
|
export { LogrotatorConfig, _default as default };
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
var config_default_default = { logrotator: {
|
|
3
|
-
disableRotateByDay: false,
|
|
4
|
-
filesRotateByHour: null,
|
|
5
|
-
hourDelimiter: "-",
|
|
6
|
-
filesRotateBySize: null,
|
|
7
|
-
maxFileSize: 50 * 1024 * 1024,
|
|
8
|
-
maxFiles: 10,
|
|
9
|
-
rotateDuration: 6e4,
|
|
10
|
-
maxDays: 31,
|
|
11
|
-
gzip: false
|
|
12
|
-
} };
|
|
1
|
+
import { config_default_default } from "../config.default-CvMzfv2b.js";
|
|
13
2
|
|
|
14
|
-
//#endregion
|
|
15
3
|
export { config_default_default as default };
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
//#region src/config/config.default.d.ts
|
|
2
|
+
interface LogrotatorConfig {
|
|
3
|
+
/**
|
|
4
|
+
* Disable rotate by day
|
|
5
|
+
*
|
|
6
|
+
* Default: `false`
|
|
7
|
+
*/
|
|
8
|
+
disableRotateByDay: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* List of files that will be rotated by hour
|
|
11
|
+
*
|
|
12
|
+
* Default: `null`
|
|
13
|
+
*/
|
|
14
|
+
filesRotateByHour: string[] | null;
|
|
15
|
+
/**
|
|
16
|
+
* Hour delimiter
|
|
17
|
+
*
|
|
18
|
+
* Default: `-`
|
|
19
|
+
*/
|
|
20
|
+
hourDelimiter: string;
|
|
21
|
+
/**
|
|
22
|
+
* List of files that will be rotated by size
|
|
23
|
+
*
|
|
24
|
+
* Default: `null`
|
|
25
|
+
*/
|
|
26
|
+
filesRotateBySize: string[] | null;
|
|
27
|
+
/**
|
|
28
|
+
* Max file size to judge if any file need rotate
|
|
29
|
+
*
|
|
30
|
+
* Default: `50 * 1024 * 1024`
|
|
31
|
+
*/
|
|
32
|
+
maxFileSize: number;
|
|
33
|
+
/**
|
|
34
|
+
* Max files to keep
|
|
35
|
+
*
|
|
36
|
+
* Default: `10`
|
|
37
|
+
*/
|
|
38
|
+
maxFiles: number;
|
|
39
|
+
/**
|
|
40
|
+
* Time interval to judge if any file need rotate
|
|
41
|
+
*
|
|
42
|
+
* Default: `60000`
|
|
43
|
+
*/
|
|
44
|
+
rotateDuration: number;
|
|
45
|
+
/**
|
|
46
|
+
* Max days to keep log files, set `0` to keep all logs.
|
|
47
|
+
*
|
|
48
|
+
* Default: `31`
|
|
49
|
+
*/
|
|
50
|
+
maxDays: number;
|
|
51
|
+
/**
|
|
52
|
+
* Enable gzip compression for rotated files
|
|
53
|
+
*
|
|
54
|
+
* Default: `false`
|
|
55
|
+
*/
|
|
56
|
+
gzip: boolean;
|
|
57
|
+
}
|
|
58
|
+
declare const _default: {
|
|
59
|
+
logrotator: LogrotatorConfig;
|
|
60
|
+
};
|
|
61
|
+
//#endregion
|
|
62
|
+
export { LogrotatorConfig, _default };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
//#region src/config/config.default.ts
|
|
2
|
+
var config_default_default = { logrotator: {
|
|
3
|
+
disableRotateByDay: false,
|
|
4
|
+
filesRotateByHour: null,
|
|
5
|
+
hourDelimiter: "-",
|
|
6
|
+
filesRotateBySize: null,
|
|
7
|
+
maxFileSize: 50 * 1024 * 1024,
|
|
8
|
+
maxFiles: 10,
|
|
9
|
+
rotateDuration: 6e4,
|
|
10
|
+
maxDays: 31,
|
|
11
|
+
gzip: false
|
|
12
|
+
} };
|
|
13
|
+
|
|
14
|
+
//#endregion
|
|
15
|
+
export { config_default_default };
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { LogRotator } from "./rotator-CRROE_AN.js";
|
|
2
|
+
import { walkLoggerFile } from "./utils-Br9jwJMb.js";
|
|
3
|
+
import fs from "node:fs/promises";
|
|
4
|
+
import { debuglog } from "node:util";
|
|
5
|
+
import { exists } from "utility";
|
|
6
|
+
import path from "node:path";
|
|
7
|
+
import moment from "moment";
|
|
8
|
+
|
|
9
|
+
//#region src/lib/day_rotator.ts
|
|
10
|
+
const debug = debuglog("egg/logrotator/lib/day_rotator");
|
|
11
|
+
var DayRotator = class extends LogRotator {
|
|
12
|
+
filesRotateBySize;
|
|
13
|
+
filesRotateByHour;
|
|
14
|
+
constructor(options) {
|
|
15
|
+
super(options);
|
|
16
|
+
this.filesRotateBySize = this.app.config.logrotator.filesRotateBySize ?? [];
|
|
17
|
+
this.filesRotateByHour = this.app.config.logrotator.filesRotateByHour ?? [];
|
|
18
|
+
}
|
|
19
|
+
async getRotateFiles() {
|
|
20
|
+
const files = /* @__PURE__ */ new Map();
|
|
21
|
+
const logDir = this.app.config.logger.dir;
|
|
22
|
+
const loggers = this.app.loggers;
|
|
23
|
+
const loggerFiles = walkLoggerFile(loggers);
|
|
24
|
+
for (let file of loggerFiles) {
|
|
25
|
+
if (!path.isAbsolute(file)) file = path.join(logDir, file);
|
|
26
|
+
this._setFile(file, files);
|
|
27
|
+
}
|
|
28
|
+
const agentLogName = this.app.config.logger.agentLogName;
|
|
29
|
+
this._setFile(path.join(logDir, agentLogName), files);
|
|
30
|
+
const rotateLogDirs = this.app.config.logger.rotateLogDirs;
|
|
31
|
+
if (rotateLogDirs && rotateLogDirs.length > 0) {
|
|
32
|
+
this.app.deprecate("[@eggjs/logrotator] Do not use app.config.logger.rotateLogDirs, only rotate core loggers and custom loggers");
|
|
33
|
+
for (const dir of rotateLogDirs) {
|
|
34
|
+
if (!await exists(dir)) continue;
|
|
35
|
+
try {
|
|
36
|
+
const names = await fs.readdir(dir);
|
|
37
|
+
for (const name of names) {
|
|
38
|
+
if (!name.endsWith(".log")) continue;
|
|
39
|
+
this._setFile(path.join(dir, name), files);
|
|
40
|
+
}
|
|
41
|
+
} catch (err) {
|
|
42
|
+
this.logger.error(err);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
return files;
|
|
47
|
+
}
|
|
48
|
+
_setFile(srcPath, files) {
|
|
49
|
+
if (this.filesRotateBySize.includes(srcPath)) return;
|
|
50
|
+
if (this.filesRotateByHour.includes(srcPath)) return;
|
|
51
|
+
if (!files.has(srcPath)) {
|
|
52
|
+
const ext = this.app.config.logrotator.gzip === true ? ".gz" : "";
|
|
53
|
+
const targetPath = srcPath + moment().subtract(23, "hours").subtract(58, "minutes").format(".YYYY-MM-DD") + ext;
|
|
54
|
+
debug("set file %s => %s", srcPath, targetPath);
|
|
55
|
+
files.set(srcPath, {
|
|
56
|
+
srcPath,
|
|
57
|
+
targetPath
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
//#endregion
|
|
64
|
+
export { DayRotator };
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { LogRotator } from "./rotator-CRROE_AN.js";
|
|
2
|
+
import { debuglog } from "node:util";
|
|
3
|
+
import { exists } from "utility";
|
|
4
|
+
import path from "node:path";
|
|
5
|
+
import moment from "moment";
|
|
6
|
+
|
|
7
|
+
//#region src/lib/hour_rotator.ts
|
|
8
|
+
const debug = debuglog("egg/logrotator/lib/hour_rotator");
|
|
9
|
+
var HourRotator = class extends LogRotator {
|
|
10
|
+
async getRotateFiles() {
|
|
11
|
+
const files = /* @__PURE__ */ new Map();
|
|
12
|
+
const logDir = this.app.config.logger.dir;
|
|
13
|
+
const filesRotateByHour = this.app.config.logrotator.filesRotateByHour ?? [];
|
|
14
|
+
for (let logPath of filesRotateByHour) {
|
|
15
|
+
if (!path.isAbsolute(logPath)) logPath = path.join(logDir, logPath);
|
|
16
|
+
if (!await exists(logPath)) continue;
|
|
17
|
+
this._setFile(logPath, files);
|
|
18
|
+
}
|
|
19
|
+
return files;
|
|
20
|
+
}
|
|
21
|
+
get hourDelimiter() {
|
|
22
|
+
return this.app.config.logrotator.hourDelimiter;
|
|
23
|
+
}
|
|
24
|
+
_setFile(srcPath, files) {
|
|
25
|
+
if (!files.has(srcPath)) {
|
|
26
|
+
const ext = this.app.config.logrotator.gzip === true ? ".gz" : "";
|
|
27
|
+
const targetPath = srcPath + moment().subtract(1, "hours").format(`.YYYY-MM-DD${this.hourDelimiter}HH`) + ext;
|
|
28
|
+
debug("set file %s => %s", srcPath, targetPath);
|
|
29
|
+
files.set(srcPath, {
|
|
30
|
+
srcPath,
|
|
31
|
+
targetPath
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
//#endregion
|
|
38
|
+
export { HourRotator };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,2 +1,5 @@
|
|
|
1
|
-
import { LogRotator, RotateFile, RotatorOptions } from "./
|
|
1
|
+
import { LogRotator, RotateFile, RotatorOptions } from "./rotator-BjJMXyaY.js";
|
|
2
|
+
import "./application-DLlqYOTH.js";
|
|
3
|
+
import "./config.default-CnLV2bGK.js";
|
|
4
|
+
import "./types-RmfrK2ke.js";
|
|
2
5
|
export { LogRotator, RotateFile, RotatorOptions };
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import "./config
|
|
2
|
-
import { LogRotator } from "./
|
|
3
|
-
import "./
|
|
1
|
+
import "./config.default-CvMzfv2b.js";
|
|
2
|
+
import { LogRotator } from "./rotator-CRROE_AN.js";
|
|
3
|
+
import "./application-DUxqk1cL.js";
|
|
4
|
+
import "./types-CQtQr8gw.js";
|
|
4
5
|
|
|
5
6
|
export { LogRotator };
|
package/dist/lib/day_rotator.js
CHANGED
|
@@ -1,64 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { debuglog } from "node:util";
|
|
5
|
-
import { exists } from "utility";
|
|
6
|
-
import path from "node:path";
|
|
7
|
-
import moment from "moment";
|
|
1
|
+
import "../rotator-CRROE_AN.js";
|
|
2
|
+
import "../utils-Br9jwJMb.js";
|
|
3
|
+
import { DayRotator } from "../day_rotator-DHd2Parx.js";
|
|
8
4
|
|
|
9
|
-
//#region src/lib/day_rotator.ts
|
|
10
|
-
const debug = debuglog("egg/logrotator/lib/day_rotator");
|
|
11
|
-
var DayRotator = class extends LogRotator {
|
|
12
|
-
filesRotateBySize;
|
|
13
|
-
filesRotateByHour;
|
|
14
|
-
constructor(options) {
|
|
15
|
-
super(options);
|
|
16
|
-
this.filesRotateBySize = this.app.config.logrotator.filesRotateBySize ?? [];
|
|
17
|
-
this.filesRotateByHour = this.app.config.logrotator.filesRotateByHour ?? [];
|
|
18
|
-
}
|
|
19
|
-
async getRotateFiles() {
|
|
20
|
-
const files = /* @__PURE__ */ new Map();
|
|
21
|
-
const logDir = this.app.config.logger.dir;
|
|
22
|
-
const loggers = this.app.loggers;
|
|
23
|
-
const loggerFiles = walkLoggerFile(loggers);
|
|
24
|
-
for (let file of loggerFiles) {
|
|
25
|
-
if (!path.isAbsolute(file)) file = path.join(logDir, file);
|
|
26
|
-
this._setFile(file, files);
|
|
27
|
-
}
|
|
28
|
-
const agentLogName = this.app.config.logger.agentLogName;
|
|
29
|
-
this._setFile(path.join(logDir, agentLogName), files);
|
|
30
|
-
const rotateLogDirs = this.app.config.logger.rotateLogDirs;
|
|
31
|
-
if (rotateLogDirs && rotateLogDirs.length > 0) {
|
|
32
|
-
this.app.deprecate("[@eggjs/logrotator] Do not use app.config.logger.rotateLogDirs, only rotate core loggers and custom loggers");
|
|
33
|
-
for (const dir of rotateLogDirs) {
|
|
34
|
-
if (!await exists(dir)) continue;
|
|
35
|
-
try {
|
|
36
|
-
const names = await fs.readdir(dir);
|
|
37
|
-
for (const name of names) {
|
|
38
|
-
if (!name.endsWith(".log")) continue;
|
|
39
|
-
this._setFile(path.join(dir, name), files);
|
|
40
|
-
}
|
|
41
|
-
} catch (err) {
|
|
42
|
-
this.logger.error(err);
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
return files;
|
|
47
|
-
}
|
|
48
|
-
_setFile(srcPath, files) {
|
|
49
|
-
if (this.filesRotateBySize.includes(srcPath)) return;
|
|
50
|
-
if (this.filesRotateByHour.includes(srcPath)) return;
|
|
51
|
-
if (!files.has(srcPath)) {
|
|
52
|
-
const ext = this.app.config.logrotator.gzip === true ? ".gz" : "";
|
|
53
|
-
const targetPath = srcPath + moment().subtract(23, "hours").subtract(58, "minutes").format(".YYYY-MM-DD") + ext;
|
|
54
|
-
debug("set file %s => %s", srcPath, targetPath);
|
|
55
|
-
files.set(srcPath, {
|
|
56
|
-
srcPath,
|
|
57
|
-
targetPath
|
|
58
|
-
});
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
};
|
|
62
|
-
|
|
63
|
-
//#endregion
|
|
64
5
|
export { DayRotator };
|
package/dist/lib/hour_rotator.js
CHANGED
|
@@ -1,38 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import { exists } from "utility";
|
|
4
|
-
import path from "node:path";
|
|
5
|
-
import moment from "moment";
|
|
1
|
+
import "../rotator-CRROE_AN.js";
|
|
2
|
+
import { HourRotator } from "../hour_rotator-JmysNFky.js";
|
|
6
3
|
|
|
7
|
-
//#region src/lib/hour_rotator.ts
|
|
8
|
-
const debug = debuglog("egg/logrotator/lib/hour_rotator");
|
|
9
|
-
var HourRotator = class extends LogRotator {
|
|
10
|
-
async getRotateFiles() {
|
|
11
|
-
const files = /* @__PURE__ */ new Map();
|
|
12
|
-
const logDir = this.app.config.logger.dir;
|
|
13
|
-
const filesRotateByHour = this.app.config.logrotator.filesRotateByHour ?? [];
|
|
14
|
-
for (let logPath of filesRotateByHour) {
|
|
15
|
-
if (!path.isAbsolute(logPath)) logPath = path.join(logDir, logPath);
|
|
16
|
-
if (!await exists(logPath)) continue;
|
|
17
|
-
this._setFile(logPath, files);
|
|
18
|
-
}
|
|
19
|
-
return files;
|
|
20
|
-
}
|
|
21
|
-
get hourDelimiter() {
|
|
22
|
-
return this.app.config.logrotator.hourDelimiter;
|
|
23
|
-
}
|
|
24
|
-
_setFile(srcPath, files) {
|
|
25
|
-
if (!files.has(srcPath)) {
|
|
26
|
-
const ext = this.app.config.logrotator.gzip === true ? ".gz" : "";
|
|
27
|
-
const targetPath = srcPath + moment().subtract(1, "hours").format(`.YYYY-MM-DD${this.hourDelimiter}HH`) + ext;
|
|
28
|
-
debug("set file %s => %s", srcPath, targetPath);
|
|
29
|
-
files.set(srcPath, {
|
|
30
|
-
srcPath,
|
|
31
|
-
targetPath
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
//#endregion
|
|
38
4
|
export { HourRotator };
|
package/dist/lib/rotator.d.ts
CHANGED
|
@@ -1,20 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
//#region src/lib/rotator.d.ts
|
|
4
|
-
interface RotatorOptions {
|
|
5
|
-
app: Application;
|
|
6
|
-
}
|
|
7
|
-
interface RotateFile {
|
|
8
|
-
srcPath: string;
|
|
9
|
-
targetPath: string;
|
|
10
|
-
}
|
|
11
|
-
declare abstract class LogRotator {
|
|
12
|
-
protected readonly options: RotatorOptions;
|
|
13
|
-
protected readonly app: Application;
|
|
14
|
-
protected readonly logger: Application['coreLogger'];
|
|
15
|
-
constructor(options: RotatorOptions);
|
|
16
|
-
abstract getRotateFiles(): Promise<Map<string, RotateFile>>;
|
|
17
|
-
rotate(): Promise<void>;
|
|
18
|
-
}
|
|
19
|
-
//#endregion
|
|
1
|
+
import { LogRotator, RotateFile, RotatorOptions } from "../rotator-BjJMXyaY.js";
|
|
20
2
|
export { LogRotator, RotateFile, RotatorOptions };
|
package/dist/lib/rotator.js
CHANGED
|
@@ -1,56 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { createReadStream, createWriteStream } from "node:fs";
|
|
3
|
-
import fs from "node:fs/promises";
|
|
4
|
-
import { pipeline } from "node:stream/promises";
|
|
5
|
-
import { createGzip } from "node:zlib";
|
|
6
|
-
import { debuglog } from "node:util";
|
|
7
|
-
import { exists } from "utility";
|
|
1
|
+
import { LogRotator } from "../rotator-CRROE_AN.js";
|
|
8
2
|
|
|
9
|
-
//#region src/lib/rotator.ts
|
|
10
|
-
const debug = debuglog("egg/logrotator/lib/rotator");
|
|
11
|
-
var LogRotator = class {
|
|
12
|
-
options;
|
|
13
|
-
app;
|
|
14
|
-
logger;
|
|
15
|
-
constructor(options) {
|
|
16
|
-
this.options = options;
|
|
17
|
-
assert(this.options.app, "options.app is required");
|
|
18
|
-
this.app = this.options.app;
|
|
19
|
-
this.logger = this.app.coreLogger;
|
|
20
|
-
}
|
|
21
|
-
async rotate() {
|
|
22
|
-
const files = await this.getRotateFiles();
|
|
23
|
-
assert(files instanceof Map, "getRotateFiles should return a Map");
|
|
24
|
-
const rotatedFiles = [];
|
|
25
|
-
for (const file of files.values()) try {
|
|
26
|
-
debug("rename from %s to %s", file.srcPath, file.targetPath);
|
|
27
|
-
await renameOrDelete(file.srcPath, file.targetPath, this.app.config.logrotator.gzip);
|
|
28
|
-
rotatedFiles.push(`${file.srcPath} -> ${file.targetPath}`);
|
|
29
|
-
} catch (e) {
|
|
30
|
-
const err = e;
|
|
31
|
-
err.message = `[@eggjs/logrotator] rename ${file.srcPath}, found exception: ${err.message}`;
|
|
32
|
-
this.logger.error(err);
|
|
33
|
-
}
|
|
34
|
-
if (rotatedFiles.length > 0) {
|
|
35
|
-
debug("broadcast log-reload, rotated files: %j", rotatedFiles);
|
|
36
|
-
this.logger.info("[@eggjs/logrotator] broadcast log-reload");
|
|
37
|
-
this.app.messenger.sendToApp("log-reload");
|
|
38
|
-
this.app.messenger.sendToAgent("log-reload");
|
|
39
|
-
}
|
|
40
|
-
this.logger.info("[@eggjs/logrotator] rotate files success by %s, files %j", this.constructor.name, rotatedFiles);
|
|
41
|
-
}
|
|
42
|
-
};
|
|
43
|
-
async function renameOrDelete(srcPath, targetPath, gzip) {
|
|
44
|
-
if (srcPath === targetPath) return;
|
|
45
|
-
if (!await exists(srcPath)) return;
|
|
46
|
-
if (await exists(targetPath)) throw /* @__PURE__ */ new Error(`targetFile ${targetPath} exists!!!`);
|
|
47
|
-
if (gzip === true) {
|
|
48
|
-
const tmpPath = `${targetPath}.tmp`;
|
|
49
|
-
await fs.rename(srcPath, tmpPath);
|
|
50
|
-
await pipeline(createReadStream(tmpPath), createGzip(), createWriteStream(targetPath));
|
|
51
|
-
await fs.unlink(tmpPath);
|
|
52
|
-
} else await fs.rename(srcPath, targetPath);
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
//#endregion
|
|
56
3
|
export { LogRotator };
|
package/dist/lib/size_rotator.js
CHANGED
|
@@ -1,61 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { debuglog } from "node:util";
|
|
4
|
-
import { exists } from "utility";
|
|
5
|
-
import path from "node:path";
|
|
1
|
+
import "../rotator-CRROE_AN.js";
|
|
2
|
+
import { SizeRotator } from "../size_rotator-B94wnaTP.js";
|
|
6
3
|
|
|
7
|
-
//#region src/lib/size_rotator.ts
|
|
8
|
-
const debug = debuglog("egg/logrotator/lib/size_rotator");
|
|
9
|
-
var SizeRotator = class extends LogRotator {
|
|
10
|
-
async getRotateFiles() {
|
|
11
|
-
const files = /* @__PURE__ */ new Map();
|
|
12
|
-
const logDir = this.app.config.logger.dir;
|
|
13
|
-
const filesRotateBySize = this.app.config.logrotator.filesRotateBySize ?? [];
|
|
14
|
-
const maxFileSize = this.app.config.logrotator.maxFileSize;
|
|
15
|
-
const maxFiles = this.app.config.logrotator.maxFiles;
|
|
16
|
-
for (let logPath of filesRotateBySize) {
|
|
17
|
-
if (!path.isAbsolute(logPath)) logPath = path.join(logDir, logPath);
|
|
18
|
-
const stat = await exists(logPath);
|
|
19
|
-
if (!stat) continue;
|
|
20
|
-
const size = stat.size;
|
|
21
|
-
try {
|
|
22
|
-
if (size >= maxFileSize) {
|
|
23
|
-
this.logger.info(`[@eggjs/logrotator] file ${logPath} reach the maximum file size, current size: ${size}, max size: ${maxFileSize}`);
|
|
24
|
-
const maxFileName = `${logPath}.${maxFiles}`;
|
|
25
|
-
if (await exists(maxFileName)) {
|
|
26
|
-
await fs.unlink(maxFileName);
|
|
27
|
-
this.logger.info(`[@eggjs/logrotator] delete max log file ${maxFileName}`);
|
|
28
|
-
}
|
|
29
|
-
this._setFile(logPath, files);
|
|
30
|
-
}
|
|
31
|
-
} catch (e) {
|
|
32
|
-
const err = e;
|
|
33
|
-
err.message = `[@eggjs/logrotator] ${err.message}`;
|
|
34
|
-
this.logger.error(err);
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
return files;
|
|
38
|
-
}
|
|
39
|
-
_setFile(logPath, files) {
|
|
40
|
-
const maxFiles = this.app.config.logrotator.maxFiles;
|
|
41
|
-
if (files.has(logPath)) return;
|
|
42
|
-
const ext = this.app.config.logrotator.gzip === true ? ".gz" : "";
|
|
43
|
-
for (let i = maxFiles - 1; i >= 1; i--) {
|
|
44
|
-
const srcPath = `${logPath}.${i}`;
|
|
45
|
-
const targetPath = `${logPath}.${i + 1}${ext}`;
|
|
46
|
-
debug("set file %s => %s", srcPath, targetPath);
|
|
47
|
-
files.set(srcPath, {
|
|
48
|
-
srcPath,
|
|
49
|
-
targetPath
|
|
50
|
-
});
|
|
51
|
-
}
|
|
52
|
-
debug("set file %s => %s", logPath, `${logPath}.1`);
|
|
53
|
-
files.set(logPath, {
|
|
54
|
-
srcPath: logPath,
|
|
55
|
-
targetPath: `${logPath}.1${ext}`
|
|
56
|
-
});
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
|
|
60
|
-
//#endregion
|
|
61
4
|
export { SizeRotator };
|
package/dist/lib/utils.js
CHANGED
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
/**
|
|
3
|
-
* Walk all logger files from loggers
|
|
4
|
-
*/
|
|
5
|
-
function walkLoggerFile(loggers) {
|
|
6
|
-
const files = [];
|
|
7
|
-
for (const registeredLogger of Object.values(loggers)) for (const transport of registeredLogger.values()) {
|
|
8
|
-
const file = transport.options.file;
|
|
9
|
-
if (file) files.push(file);
|
|
10
|
-
}
|
|
11
|
-
return files;
|
|
12
|
-
}
|
|
1
|
+
import { walkLoggerFile } from "../utils-Br9jwJMb.js";
|
|
13
2
|
|
|
14
|
-
//#endregion
|
|
15
3
|
export { walkLoggerFile };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Application } from "egg";
|
|
2
|
+
|
|
3
|
+
//#region src/lib/rotator.d.ts
|
|
4
|
+
interface RotatorOptions {
|
|
5
|
+
app: Application;
|
|
6
|
+
}
|
|
7
|
+
interface RotateFile {
|
|
8
|
+
srcPath: string;
|
|
9
|
+
targetPath: string;
|
|
10
|
+
}
|
|
11
|
+
declare abstract class LogRotator {
|
|
12
|
+
protected readonly options: RotatorOptions;
|
|
13
|
+
protected readonly app: Application;
|
|
14
|
+
protected readonly logger: Application['coreLogger'];
|
|
15
|
+
constructor(options: RotatorOptions);
|
|
16
|
+
abstract getRotateFiles(): Promise<Map<string, RotateFile>>;
|
|
17
|
+
rotate(): Promise<void>;
|
|
18
|
+
}
|
|
19
|
+
//#endregion
|
|
20
|
+
export { LogRotator, RotateFile, RotatorOptions };
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import assert from "node:assert";
|
|
2
|
+
import { createReadStream, createWriteStream } from "node:fs";
|
|
3
|
+
import fs from "node:fs/promises";
|
|
4
|
+
import { pipeline } from "node:stream/promises";
|
|
5
|
+
import { createGzip } from "node:zlib";
|
|
6
|
+
import { debuglog } from "node:util";
|
|
7
|
+
import { exists } from "utility";
|
|
8
|
+
|
|
9
|
+
//#region src/lib/rotator.ts
|
|
10
|
+
const debug = debuglog("egg/logrotator/lib/rotator");
|
|
11
|
+
var LogRotator = class {
|
|
12
|
+
options;
|
|
13
|
+
app;
|
|
14
|
+
logger;
|
|
15
|
+
constructor(options) {
|
|
16
|
+
this.options = options;
|
|
17
|
+
assert(this.options.app, "options.app is required");
|
|
18
|
+
this.app = this.options.app;
|
|
19
|
+
this.logger = this.app.coreLogger;
|
|
20
|
+
}
|
|
21
|
+
async rotate() {
|
|
22
|
+
const files = await this.getRotateFiles();
|
|
23
|
+
assert(files instanceof Map, "getRotateFiles should return a Map");
|
|
24
|
+
const rotatedFiles = [];
|
|
25
|
+
for (const file of files.values()) try {
|
|
26
|
+
debug("rename from %s to %s", file.srcPath, file.targetPath);
|
|
27
|
+
await renameOrDelete(file.srcPath, file.targetPath, this.app.config.logrotator.gzip);
|
|
28
|
+
rotatedFiles.push(`${file.srcPath} -> ${file.targetPath}`);
|
|
29
|
+
} catch (e) {
|
|
30
|
+
const err = e;
|
|
31
|
+
err.message = `[@eggjs/logrotator] rename ${file.srcPath}, found exception: ${err.message}`;
|
|
32
|
+
this.logger.error(err);
|
|
33
|
+
}
|
|
34
|
+
if (rotatedFiles.length > 0) {
|
|
35
|
+
debug("broadcast log-reload, rotated files: %j", rotatedFiles);
|
|
36
|
+
this.logger.info("[@eggjs/logrotator] broadcast log-reload");
|
|
37
|
+
this.app.messenger.sendToApp("log-reload");
|
|
38
|
+
this.app.messenger.sendToAgent("log-reload");
|
|
39
|
+
}
|
|
40
|
+
this.logger.info("[@eggjs/logrotator] rotate files success by %s, files %j", this.constructor.name, rotatedFiles);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
async function renameOrDelete(srcPath, targetPath, gzip) {
|
|
44
|
+
if (srcPath === targetPath) return;
|
|
45
|
+
if (!await exists(srcPath)) return;
|
|
46
|
+
if (await exists(targetPath)) throw /* @__PURE__ */ new Error(`targetFile ${targetPath} exists!!!`);
|
|
47
|
+
if (gzip === true) {
|
|
48
|
+
const tmpPath = `${targetPath}.tmp`;
|
|
49
|
+
await fs.rename(srcPath, tmpPath);
|
|
50
|
+
await pipeline(createReadStream(tmpPath), createGzip(), createWriteStream(targetPath));
|
|
51
|
+
await fs.unlink(tmpPath);
|
|
52
|
+
} else await fs.rename(srcPath, targetPath);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
//#endregion
|
|
56
|
+
export { LogRotator };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { LogRotator } from "./rotator-CRROE_AN.js";
|
|
2
|
+
import fs from "node:fs/promises";
|
|
3
|
+
import { debuglog } from "node:util";
|
|
4
|
+
import { exists } from "utility";
|
|
5
|
+
import path from "node:path";
|
|
6
|
+
|
|
7
|
+
//#region src/lib/size_rotator.ts
|
|
8
|
+
const debug = debuglog("egg/logrotator/lib/size_rotator");
|
|
9
|
+
var SizeRotator = class extends LogRotator {
|
|
10
|
+
async getRotateFiles() {
|
|
11
|
+
const files = /* @__PURE__ */ new Map();
|
|
12
|
+
const logDir = this.app.config.logger.dir;
|
|
13
|
+
const filesRotateBySize = this.app.config.logrotator.filesRotateBySize ?? [];
|
|
14
|
+
const maxFileSize = this.app.config.logrotator.maxFileSize;
|
|
15
|
+
const maxFiles = this.app.config.logrotator.maxFiles;
|
|
16
|
+
for (let logPath of filesRotateBySize) {
|
|
17
|
+
if (!path.isAbsolute(logPath)) logPath = path.join(logDir, logPath);
|
|
18
|
+
const stat = await exists(logPath);
|
|
19
|
+
if (!stat) continue;
|
|
20
|
+
const size = stat.size;
|
|
21
|
+
try {
|
|
22
|
+
if (size >= maxFileSize) {
|
|
23
|
+
this.logger.info(`[@eggjs/logrotator] file ${logPath} reach the maximum file size, current size: ${size}, max size: ${maxFileSize}`);
|
|
24
|
+
const maxFileName = `${logPath}.${maxFiles}`;
|
|
25
|
+
if (await exists(maxFileName)) {
|
|
26
|
+
await fs.unlink(maxFileName);
|
|
27
|
+
this.logger.info(`[@eggjs/logrotator] delete max log file ${maxFileName}`);
|
|
28
|
+
}
|
|
29
|
+
this._setFile(logPath, files);
|
|
30
|
+
}
|
|
31
|
+
} catch (e) {
|
|
32
|
+
const err = e;
|
|
33
|
+
err.message = `[@eggjs/logrotator] ${err.message}`;
|
|
34
|
+
this.logger.error(err);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
return files;
|
|
38
|
+
}
|
|
39
|
+
_setFile(logPath, files) {
|
|
40
|
+
const maxFiles = this.app.config.logrotator.maxFiles;
|
|
41
|
+
if (files.has(logPath)) return;
|
|
42
|
+
const ext = this.app.config.logrotator.gzip === true ? ".gz" : "";
|
|
43
|
+
for (let i = maxFiles - 1; i >= 1; i--) {
|
|
44
|
+
const srcPath = `${logPath}.${i}`;
|
|
45
|
+
const targetPath = `${logPath}.${i + 1}${ext}`;
|
|
46
|
+
debug("set file %s => %s", srcPath, targetPath);
|
|
47
|
+
files.set(srcPath, {
|
|
48
|
+
srcPath,
|
|
49
|
+
targetPath
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
debug("set file %s => %s", logPath, `${logPath}.1`);
|
|
53
|
+
files.set(logPath, {
|
|
54
|
+
srcPath: logPath,
|
|
55
|
+
targetPath: `${logPath}.1${ext}`
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
//#endregion
|
|
61
|
+
export { SizeRotator };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { LogRotator } from "./rotator-BjJMXyaY.js";
|
|
2
|
+
import { LogrotatorConfig } from "./config.default-CnLV2bGK.js";
|
|
3
|
+
|
|
4
|
+
//#region src/types.d.ts
|
|
5
|
+
declare module 'egg' {
|
|
6
|
+
interface EggAppConfig {
|
|
7
|
+
/**
|
|
8
|
+
* logrotator options
|
|
9
|
+
* @member Config#logrotator
|
|
10
|
+
*/
|
|
11
|
+
logrotator: LogrotatorConfig;
|
|
12
|
+
}
|
|
13
|
+
interface Agent {
|
|
14
|
+
LogRotator: typeof LogRotator;
|
|
15
|
+
}
|
|
16
|
+
interface Application {
|
|
17
|
+
LogRotator: typeof LogRotator;
|
|
18
|
+
}
|
|
19
|
+
}
|
package/dist/types.d.ts
CHANGED
|
@@ -1,19 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
//#region src/types.d.ts
|
|
5
|
-
declare module 'egg' {
|
|
6
|
-
interface EggAppConfig {
|
|
7
|
-
/**
|
|
8
|
-
* logrotator options
|
|
9
|
-
* @member Config#logrotator
|
|
10
|
-
*/
|
|
11
|
-
logrotator: LogrotatorConfig;
|
|
12
|
-
}
|
|
13
|
-
interface Agent {
|
|
14
|
-
LogRotator: typeof LogRotator;
|
|
15
|
-
}
|
|
16
|
-
interface Application {
|
|
17
|
-
LogRotator: typeof LogRotator;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
1
|
+
import "./rotator-BjJMXyaY.js";
|
|
2
|
+
import "./config.default-CnLV2bGK.js";
|
|
3
|
+
import "./types-RmfrK2ke.js";
|
package/dist/types.js
CHANGED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
//#region src/lib/utils.ts
|
|
2
|
+
/**
|
|
3
|
+
* Walk all logger files from loggers
|
|
4
|
+
*/
|
|
5
|
+
function walkLoggerFile(loggers) {
|
|
6
|
+
const files = [];
|
|
7
|
+
for (const registeredLogger of Object.values(loggers)) for (const transport of registeredLogger.values()) {
|
|
8
|
+
const file = transport.options.file;
|
|
9
|
+
if (file) files.push(file);
|
|
10
|
+
}
|
|
11
|
+
return files;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
//#endregion
|
|
15
|
+
export { walkLoggerFile };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eggjs/logrotator",
|
|
3
|
-
"version": "5.0.0-beta.
|
|
3
|
+
"version": "5.0.0-beta.20",
|
|
4
4
|
"description": "logrotator for egg",
|
|
5
5
|
"eggPlugin": {
|
|
6
6
|
"name": "logrotator",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"utility": "^2.5.0"
|
|
59
59
|
},
|
|
60
60
|
"peerDependencies": {
|
|
61
|
-
"egg": "4.1.0-beta.
|
|
61
|
+
"egg": "4.1.0-beta.20"
|
|
62
62
|
},
|
|
63
63
|
"devDependencies": {
|
|
64
64
|
"@types/node": "^24.6.2",
|
|
@@ -67,9 +67,9 @@
|
|
|
67
67
|
"tsdown": "^0.15.4",
|
|
68
68
|
"typescript": "^5.9.3",
|
|
69
69
|
"vitest": "4.0.0-beta.16",
|
|
70
|
-
"@eggjs/mock": "7.0.0-beta.
|
|
71
|
-
"@eggjs/schedule": "6.0.0-beta.
|
|
72
|
-
"@eggjs/tsconfig": "3.1.0-beta.
|
|
70
|
+
"@eggjs/mock": "7.0.0-beta.20",
|
|
71
|
+
"@eggjs/schedule": "6.0.0-beta.20",
|
|
72
|
+
"@eggjs/tsconfig": "3.1.0-beta.20"
|
|
73
73
|
},
|
|
74
74
|
"files": [
|
|
75
75
|
"dist"
|