@scoutflo/alert-correlation 0.4.0 → 0.4.1
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/src/contracts/topology.d.ts +8 -0
- package/dist/src/decision/coreCompatibility.d.ts +5 -0
- package/dist/src/decision/coreCompatibility.js +54 -0
- package/dist/src/decision/coreCompatibility.js.map +1 -0
- package/dist/src/index.d.ts +3 -0
- package/dist/src/index.js +8 -1
- package/dist/src/index.js.map +1 -1
- package/dist/test/core-compatibility.test.js +59 -0
- package/dist/test/core-compatibility.test.js.map +1 -1
- package/package.json +2 -1
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { CorrelationEntityRef, CorrelationEntityType } from '@scoutflo/correlation-core';
|
|
2
|
+
import type { TopologyCorrelationContractKey, TopologyCorrelationContractVersion } from '@scoutflo/topology-contracts';
|
|
2
3
|
export type { CorrelationEntityType };
|
|
3
4
|
export type CorrelationTopologyEntityRef = CorrelationEntityRef;
|
|
4
5
|
export interface CorrelationService {
|
|
@@ -25,7 +26,14 @@ export interface CorrelationRelationship {
|
|
|
25
26
|
from: CorrelationTopologyEntityRef;
|
|
26
27
|
to: CorrelationTopologyEntityRef;
|
|
27
28
|
attributeSchemaKey?: string;
|
|
29
|
+
attribute_schema_key?: string;
|
|
30
|
+
correlationContractKey?: TopologyCorrelationContractKey;
|
|
31
|
+
correlationContractVersion?: TopologyCorrelationContractVersion;
|
|
32
|
+
correlation_contract_key?: TopologyCorrelationContractKey;
|
|
33
|
+
correlation_contract_version?: TopologyCorrelationContractVersion;
|
|
28
34
|
attributes?: Record<string, unknown>;
|
|
35
|
+
sourceAttributes?: Record<string, unknown>;
|
|
36
|
+
source_attributes?: Record<string, unknown>;
|
|
29
37
|
}
|
|
30
38
|
export interface TopologyCandidateInput {
|
|
31
39
|
sourceResource: CorrelationTopologyResource | null;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { CorrelationCandidate as CoreCorrelationCandidate, CorrelationDecision as CoreCorrelationDecision, CorrelationEvidence as CoreCorrelationEvidence } from '@scoutflo/correlation-core';
|
|
2
|
+
import type { AlertCorrelationDecision, CorrelationCandidate, CorrelationEvidence } from '../contracts/decision';
|
|
3
|
+
export declare function legacyEvidenceToCoreEvidence(evidence: CorrelationEvidence): CoreCorrelationEvidence;
|
|
4
|
+
export declare function legacyCandidateToCoreCandidate(candidate: CorrelationCandidate): CoreCorrelationCandidate;
|
|
5
|
+
export declare function legacyDecisionToCoreDecision(decision: AlertCorrelationDecision): CoreCorrelationDecision;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.legacyEvidenceToCoreEvidence = legacyEvidenceToCoreEvidence;
|
|
4
|
+
exports.legacyCandidateToCoreCandidate = legacyCandidateToCoreCandidate;
|
|
5
|
+
exports.legacyDecisionToCoreDecision = legacyDecisionToCoreDecision;
|
|
6
|
+
const CORE_STATUS_BY_LEGACY_STATUS = {
|
|
7
|
+
resolved: 'resolved',
|
|
8
|
+
ambiguous: 'ambiguous',
|
|
9
|
+
degraded: 'degraded',
|
|
10
|
+
unresolved: 'unresolved',
|
|
11
|
+
evidence_available_topology_missing: 'degraded',
|
|
12
|
+
insufficient_evidence: 'unresolved',
|
|
13
|
+
};
|
|
14
|
+
function factFromLegacyEvidence(evidence) {
|
|
15
|
+
if (!evidence.factKey || evidence.factValue === undefined) {
|
|
16
|
+
return undefined;
|
|
17
|
+
}
|
|
18
|
+
return [
|
|
19
|
+
{
|
|
20
|
+
key: evidence.factKey,
|
|
21
|
+
value: evidence.factValue,
|
|
22
|
+
sourcePath: `legacy_alert_correlation.${evidence.kind}.${evidence.factKey}`,
|
|
23
|
+
confidence: 1,
|
|
24
|
+
kind: evidence.kind === 'raw_alert_field' ? 'text_derived' : 'resource_hint',
|
|
25
|
+
},
|
|
26
|
+
];
|
|
27
|
+
}
|
|
28
|
+
function legacyEvidenceToCoreEvidence(evidence) {
|
|
29
|
+
return {
|
|
30
|
+
type: evidence.kind,
|
|
31
|
+
ref: evidence.relationshipId ?? `legacy_alert_correlation:${evidence.kind}`,
|
|
32
|
+
summary: evidence.reason,
|
|
33
|
+
facts: factFromLegacyEvidence(evidence),
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
function legacyCandidateToCoreCandidate(candidate) {
|
|
37
|
+
return {
|
|
38
|
+
target: candidate.target,
|
|
39
|
+
score: candidate.confidence,
|
|
40
|
+
evidence: candidate.evidence.map(legacyEvidenceToCoreEvidence),
|
|
41
|
+
reasonCodes: candidate.reasonCodes,
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
function legacyDecisionToCoreDecision(decision) {
|
|
45
|
+
return {
|
|
46
|
+
status: CORE_STATUS_BY_LEGACY_STATUS[decision.status],
|
|
47
|
+
target: decision.target,
|
|
48
|
+
candidates: decision.candidates.map(legacyCandidateToCoreCandidate),
|
|
49
|
+
evidence: decision.evidence.map(legacyEvidenceToCoreEvidence),
|
|
50
|
+
confidence: decision.confidence,
|
|
51
|
+
reasonCodes: decision.reasonCodes,
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
//# sourceMappingURL=coreCompatibility.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"coreCompatibility.js","sourceRoot":"","sources":["../../../src/decision/coreCompatibility.ts"],"names":[],"mappings":";;AAuCA,oEASC;AAED,wEASC;AAED,oEAWC;AA1DD,MAAM,4BAA4B,GAAqD;IACrF,QAAQ,EAAE,UAAU;IACpB,SAAS,EAAE,WAAW;IACtB,QAAQ,EAAE,UAAU;IACpB,UAAU,EAAE,YAAY;IACxB,mCAAmC,EAAE,UAAU;IAC/C,qBAAqB,EAAE,YAAY;CACpC,CAAC;AAEF,SAAS,sBAAsB,CAAC,QAA6B;IAC3D,IAAI,CAAC,QAAQ,CAAC,OAAO,IAAI,QAAQ,CAAC,SAAS,KAAK,SAAS,EA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AQ,CAAC,WAAW;KAClC,CAAC;AACJ,CAAC"}
|
package/dist/src/index.d.ts
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
export declare const ALERT_CORRELATION_PACKAGE = "@scoutflo/alert-correlation";
|
|
2
2
|
export * as correlationCore from '@scoutflo/correlation-core';
|
|
3
3
|
export { confidenceSchema, correlationEvidenceSchema, correlationFactSchema, createCorrelationContractRegistry, CorrelationContractRegistry, } from '@scoutflo/correlation-core';
|
|
4
|
+
export { connectionContractRef, getConnectionContract, listActiveConnectionContracts, listConnectionContracts, topologyCorrelationContractRefSchema, } from '@scoutflo/topology-contracts';
|
|
4
5
|
export type { Confidence, CorrelationContract, CorrelationFact, CorrelationEvidence as CoreCorrelationEvidence, CorrelationProjector, CorrelationProjectorInput, CorrelationView, EndpointSpec, MatchKey, } from '@scoutflo/correlation-core';
|
|
6
|
+
export type { ConnectionContractMetadata, ConnectionContractRef, TopologyCorrelationContractKey, TopologyCorrelationContractRef, TopologyCorrelationContractVersion, } from '@scoutflo/topology-contracts';
|
|
5
7
|
export * from './contracts/alertRef';
|
|
6
8
|
export * from './contracts/alertEvidence';
|
|
7
9
|
export * from './contracts/facts';
|
|
@@ -17,6 +19,7 @@ export * from './extractors/victoriaMetricsExtractor';
|
|
|
17
19
|
export * from './extractors/registry';
|
|
18
20
|
export * from './decision/reasonCodes';
|
|
19
21
|
export * from './decision/decideTarget';
|
|
22
|
+
export * from './decision/coreCompatibility';
|
|
20
23
|
export * from './matchers/types';
|
|
21
24
|
export * from './matchers/providerRelationshipMatcher';
|
|
22
25
|
export * from './resolveAlertCorrelation';
|
package/dist/src/index.js
CHANGED
|
@@ -36,7 +36,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
36
36
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.CorrelationContractRegistry = exports.createCorrelationContractRegistry = exports.correlationFactSchema = exports.correlationEvidenceSchema = exports.confidenceSchema = exports.correlationCore = exports.ALERT_CORRELATION_PACKAGE = void 0;
|
|
39
|
+
exports.topologyCorrelationContractRefSchema = exports.listConnectionContracts = exports.listActiveConnectionContracts = exports.getConnectionContract = exports.connectionContractRef = exports.CorrelationContractRegistry = exports.createCorrelationContractRegistry = exports.correlationFactSchema = exports.correlationEvidenceSchema = exports.confidenceSchema = exports.correlationCore = exports.ALERT_CORRELATION_PACKAGE = void 0;
|
|
40
40
|
exports.ALERT_CORRELATION_PACKAGE = '@scoutflo/alert-correlation';
|
|
41
41
|
exports.correlationCore = __importStar(require("@scoutflo/correlation-core"));
|
|
42
42
|
var correlation_core_1 = require("@scoutflo/correlation-core");
|
|
@@ -45,6 +45,12 @@ Object.defineProperty(exports, "correlationEvidenceSchema", { enumerable: true,
|
|
|
45
45
|
Object.defineProperty(exports, "correlationFactSchema", { enumerable: true, get: function () { return correlation_core_1.correlationFactSchema; } });
|
|
46
46
|
Object.defineProperty(exports, "createCorrelationContractRegistry", { enumerable: true, get: function () { return correlation_core_1.createCorrelationContractRegistry; } });
|
|
47
47
|
Object.defineProperty(exports, "CorrelationContractRegistry", { enumerable: true, get: function () { return correlation_core_1.CorrelationContractRegistry; } });
|
|
48
|
+
var topology_contracts_1 = require("@scoutflo/topology-contracts");
|
|
49
|
+
Object.defineProperty(exports, "connectionContractRef", { enumerable: true, get: function () { return topology_contracts_1.connectionContractRef; } });
|
|
50
|
+
Object.defineProperty(exports, "getConnectionContract", { enumerable: true, get: function () { return topology_contracts_1.getConnectionContract; } });
|
|
51
|
+
Object.defineProperty(exports, "listActiveConnectionContracts", { enumerable: true, get: function () { return topology_contracts_1.listActiveConnectionContracts; } });
|
|
52
|
+
Object.defineProperty(exports, "listConnectionContracts", { enumerable: true, get: function () { return topology_contracts_1.listConnectionContracts; } });
|
|
53
|
+
Object.defineProperty(exports, "topologyCorrelationContractRefSchema", { enumerable: true, get: function () { return topology_contracts_1.topologyCorrelationContractRefSchema; } });
|
|
48
54
|
__exportStar(require("./contracts/alertRef"), exports);
|
|
49
55
|
__exportStar(require("./contracts/alertEvidence"), exports);
|
|
50
56
|
__exportStar(require("./contracts/facts"), exports);
|
|
@@ -60,6 +66,7 @@ __exportStar(require("./extractors/victoriaMetricsExtractor"), exports);
|
|
|
60
66
|
__exportStar(require("./extractors/registry"), exports);
|
|
61
67
|
__exportStar(require("./decision/reasonCodes"), exports);
|
|
62
68
|
__exportStar(require("./decision/decideTarget"), exports);
|
|
69
|
+
__exportStar(require("./decision/coreCompatibility"), exports);
|
|
63
70
|
__exportStar(require("./matchers/types"), exports);
|
|
64
71
|
__exportStar(require("./matchers/providerRelationshipMatcher"), exports);
|
|
65
72
|
__exportStar(require("./resolveAlertCorrelation"), exports);
|
package/dist/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAa,QAAA,yBAAyB,GAAG,6BAA6B,CAAC;AAEvE,8EAA8D;AAC9D,+DAMoC;AALlC,oHAAA,gBAAgB,OAAA;AAChB,6HAAA,yBAAyB,OAAA;AACzB,yHAAA,qBAAqB,OAAA;AACrB,qIAAA,iCAAiC,OAAA;AACjC,+HAAA,2BAA2B,OAAA;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAa,QAAA,yBAAyB,GAAG,6BAA6B,CAAC;AAEvE,8EAA8D;AAC9D,+DAMoC;AALlC,oHAAA,gBAAgB,OAAA;AAChB,6HAAA,yBAAyB,OAAA;AACzB,yHAAA,qBAAqB,OAAA;AACrB,qIAAA,iCAAiC,OAAA;AACjC,+HAAA,2BAA2B,OAAA;AAE7B,mEAMsC;AALpC,2HAAA,qBAAqB,OAAA;AACrB,2HAAA,qBAAqB,OAAA;AACrB,mIAAA,6BAA6B,OAAA;AAC7B,6HAAA,uBAAuB,OAAA;AACvB,0IAAA,oCAAoC,OAAA;AAqBtC,uDAAqC;AACrC,4DAA0C;AAC1C,oDAAkC;AAClC,uDAAqC;AACrC,uDAAqC;AACrC,sDAAoC;AACpC,4DAA0C;AAC1C,qDAAmC;AACnC,gEAA8C;AAC9C,mEAAiD;AACjD,+DAA6C;AAC7C,wEAAsD;AACtD,wDAAsC;AACtC,yDAAuC;AACvC,0DAAwC;AACxC,+DAA6C;AAC7C,mDAAiC;AACjC,yEAAuD;AACvD,4DAA0C"}
|
|
@@ -84,4 +84,63 @@ const src_1 = require("../src");
|
|
|
84
84
|
strict_1.default.equal(fact.namespace, 'kubernetes');
|
|
85
85
|
strict_1.default.equal(evidence.provider, 'prometheus');
|
|
86
86
|
});
|
|
87
|
+
(0, node_test_1.default)('correlation relationships can transport connection contract refs and source attributes', () => {
|
|
88
|
+
const relationship = {
|
|
89
|
+
id: 'rel-1',
|
|
90
|
+
relation: 'SENDS_METRICS_TO',
|
|
91
|
+
from: { type: 'service', id: 'svc-checkout' },
|
|
92
|
+
to: { type: 'resource', id: 'res-prometheus' },
|
|
93
|
+
attributeSchemaKey: 'monitoring.prometheus',
|
|
94
|
+
attribute_schema_key: 'monitoring.prometheus',
|
|
95
|
+
correlationContractKey: 'k8s_workload_sends_metrics_to_prometheus_compatible',
|
|
96
|
+
correlationContractVersion: 'v1',
|
|
97
|
+
correlation_contract_key: 'k8s_workload_sends_metrics_to_prometheus_compatible',
|
|
98
|
+
correlation_contract_version: 'v1',
|
|
99
|
+
attributes: { workload_name: 'checkout' },
|
|
100
|
+
sourceAttributes: {
|
|
101
|
+
prometheus: { serviceLabel: 'checkout' },
|
|
102
|
+
},
|
|
103
|
+
source_attributes: {
|
|
104
|
+
prometheus: { serviceLabel: 'checkout' },
|
|
105
|
+
},
|
|
106
|
+
};
|
|
107
|
+
strict_1.default.deepEqual(src_1.topologyCorrelationContractRefSchema.parse({
|
|
108
|
+
correlation_contract_key: relationship.correlation_contract_key,
|
|
109
|
+
correlation_contract_version: relationship.correlation_contract_version,
|
|
110
|
+
}), {
|
|
111
|
+
correlation_contract_key: 'k8s_workload_sends_metrics_to_prometheus_compatible',
|
|
112
|
+
correlation_contract_version: 'v1',
|
|
113
|
+
});
|
|
114
|
+
});
|
|
115
|
+
(0, node_test_1.default)('legacy alert candidates and decisions can be converted to core schemas', () => {
|
|
116
|
+
const candidate = {
|
|
117
|
+
target: { type: 'service', id: 'svc-checkout' },
|
|
118
|
+
name: 'checkout',
|
|
119
|
+
confidence: 12,
|
|
120
|
+
evidence: [
|
|
121
|
+
{
|
|
122
|
+
kind: 'relationship_attribute',
|
|
123
|
+
factKey: 'deployment',
|
|
124
|
+
factValue: 'checkout',
|
|
125
|
+
relationshipId: 'rel-1',
|
|
126
|
+
reason: 'deployment exact match',
|
|
127
|
+
},
|
|
128
|
+
],
|
|
129
|
+
reasonCodes: ['relationship_attribute_match'],
|
|
130
|
+
};
|
|
131
|
+
const decision = {
|
|
132
|
+
status: 'resolved',
|
|
133
|
+
target: candidate.target,
|
|
134
|
+
candidates: [candidate],
|
|
135
|
+
evidence: candidate.evidence,
|
|
136
|
+
confidence: candidate.confidence,
|
|
137
|
+
reasonCodes: candidate.reasonCodes,
|
|
138
|
+
};
|
|
139
|
+
const coreCandidate = src_1.correlationCore.correlationCandidateSchema.parse((0, src_1.legacyCandidateToCoreCandidate)(candidate));
|
|
140
|
+
const coreDecision = src_1.correlationCore.correlationDecisionSchema.parse((0, src_1.legacyDecisionToCoreDecision)(decision));
|
|
141
|
+
strict_1.default.equal(coreCandidate.score, 12);
|
|
142
|
+
strict_1.default.equal(coreCandidate.evidence[0]?.type, 'relationship_attribute');
|
|
143
|
+
strict_1.default.equal(coreDecision.status, 'resolved');
|
|
144
|
+
strict_1.default.equal(coreDecision.candidates[0]?.score, 12);
|
|
145
|
+
});
|
|
87
146
|
//# sourceMappingURL=core-compatibility.test.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core-compatibility.test.js","sourceRoot":"","sources":["../../test/core-compatibility.test.ts"],"names":[],"mappings":";;;;;AAAA,gEAAwC;AACxC,0DAA6B;AAC7B,
|
|
1
|
+
{"version":3,"file":"core-compatibility.test.js","sourceRoot":"","sources":["../../test/core-compatibility.test.ts"],"names":[],"mappings":";;;;;AAAA,gEAAwC;AACxC,0DAA6B;AAC7B,gCAegB;AAEhB,IAAA,mBAAI,EAAC,yCAAyC,EAAE,GAAG,EAAE;IACnD,MAAM,IAAI,GAAS;QACjB,GAAG,EAAE,SAAS;QACd,KAAK,EAAE,UAAU;QACjB,UAAU,EAAE,gBAAgB;QAC5B,UAAU,EAAE,GAAG;QACf,IAAI,EAAE,OAAO;KACd,CAAC;IAEF,MAAM,MAAM,GAAG,qBAAe,CAAC,qBAAqB,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAEjE,gBAAM,CAAC,KAAK,CAAC,MAAM,CAAC,GAAG,EAAE,SAAS,CAAC,CAAC;IACpC,gBAAM,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACrC,CAAC,CAAC,CAAC;AAEH,IAAA,mBAAI,EAAC,0DAA0D,EAAE,GAAG,EAAE;IACpE,MAAM,GAAG,GAAiC;QACxC,IAAI,EAAE,SAAS;QACf,EAAE,EAAE,cAAc;KACnB,CAAC;IAEF,MAAM,MAAM,GAAG,qBAAe,CAAC,0BAA0B,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAErE,gBAAM,CAAC,SAAS,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;AAChC,CAAC,CAAC,CAAC;AAEH,IAAA,mBAAI,EAAC,4DAA4D,EAAE,GAAG,EAAE;IACtE,MAAM,SAAS,GAAyB;QACtC,MAAM,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,EAAE,EAA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S,CAAC,CAC1C,CAAC;IACF,MAAM,YAAY,GAAG,qBAAe,CAAC,yBAAyB,CAAC,KAAK,CAClE,IAAA,kCAA4B,EAAC,QAAQ,CAAC,CACvC,CAAC;IAEF,gBAAM,CAAC,KAAK,CAAC,aAAa,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;IACtC,gBAAM,CAAC,KAAK,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,wBAAwB,CAAC,CAAC;IACxE,gBAAM,CAAC,KAAK,CAAC,YAAY,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;IAC9C,gBAAM,CAAC,KAAK,CAAC,YAAY,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,CAAC,CAAC;AACtD,CAAC,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scoutflo/alert-correlation",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Pure alert-to-topology correlation contracts and policies for Scoutflo alert investigation workflows.",
|
|
5
5
|
"main": "dist/src/index.js",
|
|
6
6
|
"types": "dist/src/index.d.ts",
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
"license": "MIT",
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"@scoutflo/correlation-core": "0.2.0",
|
|
23
|
+
"@scoutflo/topology-contracts": "0.7.8",
|
|
23
24
|
"zod": "^3.23.8"
|
|
24
25
|
},
|
|
25
26
|
"devDependencies": {
|