@appland/scanner 1.59.0 → 1.60.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/CHANGELOG.md +21 -0
- package/built/check.js +2 -0
- package/built/checkInstance.js +3 -0
- package/built/cli/scan/watchScan.js +7 -2
- package/built/ruleChecker.js +1 -0
- package/built/telemetry.js +1 -2
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,24 @@
|
|
|
1
|
+
# [@appland/scanner-v1.60.0](https://github.com/applandinc/appmap-js/compare/@appland/scanner-v1.59.2...@appland/scanner-v1.60.0) (2022-06-30)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* pass down impactDomain from Rule to Finding ([8755041](https://github.com/applandinc/appmap-js/commit/875504183a8517fec316b5f188d269de053ceef8))
|
|
7
|
+
|
|
8
|
+
# [@appland/scanner-v1.59.2](https://github.com/applandinc/appmap-js/compare/@appland/scanner-v1.59.1...@appland/scanner-v1.59.2) (2022-06-29)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* Use absolute paths when creating watchers ([afc81e0](https://github.com/applandinc/appmap-js/commit/afc81e03f1e5004288acda75c89bb61a1857c462))
|
|
14
|
+
|
|
15
|
+
# [@appland/scanner-v1.59.1](https://github.com/applandinc/appmap-js/compare/@appland/scanner-v1.59.0...@appland/scanner-v1.59.1) (2022-06-15)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Bug Fixes
|
|
19
|
+
|
|
20
|
+
* Upgrade @appland/models to v1.16.1 ([7eead86](https://github.com/applandinc/appmap-js/commit/7eead8607f30299150dd08032142a3aba5770f89))
|
|
21
|
+
|
|
1
22
|
# [@appland/scanner-v1.59.0](https://github.com/applandinc/appmap-js/compare/@appland/scanner-v1.58.0...@appland/scanner-v1.59.0) (2022-06-08)
|
|
2
23
|
|
|
3
24
|
|
package/built/check.js
CHANGED
|
@@ -14,6 +14,8 @@ class Check {
|
|
|
14
14
|
this.excludeScope = [];
|
|
15
15
|
this.includeEvent = [];
|
|
16
16
|
this.excludeEvent = [];
|
|
17
|
+
//TODO: Create Default value for impact domain
|
|
18
|
+
this.impactDomain = rule.impactDomain;
|
|
17
19
|
}
|
|
18
20
|
filterScope(event, appMapIndex) {
|
|
19
21
|
if (this.includeScope.length > 0 && !this.includeScope.every((fn) => fn(event, appMapIndex))) {
|
package/built/checkInstance.js
CHANGED
|
@@ -44,6 +44,7 @@ const fs_1 = require("fs");
|
|
|
44
44
|
const util_1 = require("util");
|
|
45
45
|
const configurationProvider_1 = require("../../configuration/configurationProvider");
|
|
46
46
|
const assert_1 = __importDefault(require("assert"));
|
|
47
|
+
const path_1 = __importDefault(require("path"));
|
|
47
48
|
class Watcher {
|
|
48
49
|
constructor(options) {
|
|
49
50
|
this.options = options;
|
|
@@ -57,10 +58,14 @@ class Watcher {
|
|
|
57
58
|
this.configWatcher
|
|
58
59
|
.on('add', this.reloadConfig.bind(this))
|
|
59
60
|
.on('change', this.reloadConfig.bind(this));
|
|
60
|
-
|
|
61
|
+
// Chokidar struggles with relative paths. Make sure the watch pattern is absolute.
|
|
62
|
+
const watchPattern = path_1.default.resolve(this.options.appmapDir, '**', 'mtime');
|
|
63
|
+
this.appmapWatcher = chokidar.watch(watchPattern, {
|
|
61
64
|
ignoreInitial: true,
|
|
62
65
|
});
|
|
63
|
-
this.appmapWatcher
|
|
66
|
+
this.appmapWatcher
|
|
67
|
+
.on('add', (filePath) => this.scan(filePath))
|
|
68
|
+
.on('change', (filePath) => this.scan(filePath));
|
|
64
69
|
});
|
|
65
70
|
}
|
|
66
71
|
close() {
|
package/built/ruleChecker.js
CHANGED
|
@@ -137,6 +137,7 @@ class RuleChecker {
|
|
|
137
137
|
groupMessage,
|
|
138
138
|
occurranceCount,
|
|
139
139
|
relatedEvents: relatedEvents.sort((event) => event.id),
|
|
140
|
+
impactDomain: checkInstance.checkImpactDomain,
|
|
140
141
|
};
|
|
141
142
|
};
|
|
142
143
|
const matchResult = yield checkInstance.ruleLogic.matcher(event, appMapIndex, checkInstance.filterEvent.bind(checkInstance));
|
package/built/telemetry.js
CHANGED
|
@@ -125,7 +125,7 @@ const transformProps = (obj) => {
|
|
|
125
125
|
};
|
|
126
126
|
class Telemetry {
|
|
127
127
|
static get enabled() {
|
|
128
|
-
return
|
|
128
|
+
return process.env.APPMAP_TELEMETRY_DISABLED === undefined;
|
|
129
129
|
}
|
|
130
130
|
static get session() {
|
|
131
131
|
var _a;
|
|
@@ -211,5 +211,4 @@ class Telemetry {
|
|
|
211
211
|
}
|
|
212
212
|
exports.default = Telemetry;
|
|
213
213
|
Telemetry.debug = process.env.APPMAP_TELEMETRY_DEBUG !== undefined;
|
|
214
|
-
Telemetry._enabled = process.env.APPMAP_TELEMETRY_DISABLED === undefined;
|
|
215
214
|
Telemetry.machineId = getMachineId();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@appland/scanner",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.60.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"bin": "built/cli.js",
|
|
6
6
|
"files": [
|
|
@@ -56,8 +56,8 @@
|
|
|
56
56
|
},
|
|
57
57
|
"dependencies": {
|
|
58
58
|
"@appland/client": "^1.3.0",
|
|
59
|
-
"@appland/models": "^1.
|
|
60
|
-
"@appland/openapi": "1.0.
|
|
59
|
+
"@appland/models": "^1.16.1",
|
|
60
|
+
"@appland/openapi": "1.0.2",
|
|
61
61
|
"@appland/sql-parser": "^1.5.0",
|
|
62
62
|
"@types/cli-progress": "^3.9.2",
|
|
63
63
|
"ajv": "^8.8.2",
|