@octaviaflow/telemetry-config-schema 1.1.1 → 1.1.2
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.
|
@@ -1,50 +1,175 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright OctaviaFlow
|
|
3
|
+
* Author: Vishal Kumar
|
|
4
|
+
* Created: 11/November/2025
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Configuration outline for metrics collection using octaviaflow telemetry.
|
|
11
|
+
*/
|
|
1
12
|
export interface ConfigSchema {
|
|
13
|
+
/**
|
|
14
|
+
* Current schema version.
|
|
15
|
+
*/
|
|
2
16
|
version: 1;
|
|
17
|
+
/**
|
|
18
|
+
* Unique identifier assigned on a per-project basis.
|
|
19
|
+
*/
|
|
3
20
|
projectId: string;
|
|
21
|
+
/**
|
|
22
|
+
* Telemetry configuration for OctaviaFlow Telemetry.
|
|
23
|
+
*/
|
|
4
24
|
name?: string;
|
|
25
|
+
/**
|
|
26
|
+
* Storage configuration for telemetry data.
|
|
27
|
+
*/
|
|
5
28
|
storage: StorageConfig;
|
|
29
|
+
/**
|
|
30
|
+
* The keys under `collect` represent the various types of data that Telemetry is capable of collecting (i.e. `scopes`).
|
|
31
|
+
*/
|
|
6
32
|
collect: CollectConfig;
|
|
7
33
|
}
|
|
34
|
+
/**
|
|
35
|
+
* Storage configuration options
|
|
36
|
+
*/
|
|
8
37
|
export interface StorageConfig {
|
|
38
|
+
/**
|
|
39
|
+
* Storage type - currently supports 'file' with future MongoDB support
|
|
40
|
+
*/
|
|
9
41
|
type: 'file' | 'mongodb';
|
|
42
|
+
/**
|
|
43
|
+
* Configuration specific to file storage
|
|
44
|
+
*/
|
|
10
45
|
file?: FileStorageConfig;
|
|
46
|
+
/**
|
|
47
|
+
* Configuration specific to MongoDB storage (future use)
|
|
48
|
+
*/
|
|
11
49
|
mongodb?: MongoDBStorageConfig;
|
|
12
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* File storage configuration
|
|
53
|
+
*/
|
|
13
54
|
export interface FileStorageConfig {
|
|
55
|
+
/**
|
|
56
|
+
* Directory path where telemetry files will be stored
|
|
57
|
+
*/
|
|
14
58
|
directory: string;
|
|
59
|
+
/**
|
|
60
|
+
* File name pattern for telemetry logs
|
|
61
|
+
* @default "octaviaflow-telemetry-{timestamp}.json"
|
|
62
|
+
*/
|
|
15
63
|
fileNamePattern?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Maximum file size in MB before rotating to a new file
|
|
66
|
+
* @default 10
|
|
67
|
+
*/
|
|
16
68
|
maxFileSizeMB?: number;
|
|
69
|
+
/**
|
|
70
|
+
* Whether to compress old files
|
|
71
|
+
* @default false
|
|
72
|
+
*/
|
|
17
73
|
compress?: boolean;
|
|
18
74
|
}
|
|
75
|
+
/**
|
|
76
|
+
* MongoDB storage configuration (for future use)
|
|
77
|
+
*/
|
|
19
78
|
export interface MongoDBStorageConfig {
|
|
79
|
+
/**
|
|
80
|
+
* MongoDB connection string
|
|
81
|
+
*/
|
|
20
82
|
connectionString: string;
|
|
83
|
+
/**
|
|
84
|
+
* Database name
|
|
85
|
+
*/
|
|
21
86
|
database: string;
|
|
87
|
+
/**
|
|
88
|
+
* Collection name for telemetry data
|
|
89
|
+
*/
|
|
22
90
|
collection: string;
|
|
23
91
|
}
|
|
92
|
+
/**
|
|
93
|
+
* Collection configuration
|
|
94
|
+
*/
|
|
24
95
|
export interface CollectConfig {
|
|
96
|
+
/**
|
|
97
|
+
* Configuration for collecting telemetry data from an npm environment.
|
|
98
|
+
*/
|
|
25
99
|
npm?: NpmScopeConfig;
|
|
100
|
+
/**
|
|
101
|
+
* Configuration for collecting telemetry data from JSX files.
|
|
102
|
+
*/
|
|
26
103
|
jsx?: JsxScopeConfig;
|
|
104
|
+
/**
|
|
105
|
+
* Configuration for collecting telemetry data for tokens and functions.
|
|
106
|
+
*/
|
|
27
107
|
js?: JsScopeConfig;
|
|
108
|
+
/**
|
|
109
|
+
* Configuration for collecting telemetry data from HTML and JSX files.
|
|
110
|
+
*/
|
|
28
111
|
wc?: WcScopeConfig;
|
|
29
112
|
}
|
|
113
|
+
/**
|
|
114
|
+
* NPM scope configuration
|
|
115
|
+
*/
|
|
30
116
|
export interface NpmScopeConfig {
|
|
117
|
+
/**
|
|
118
|
+
* Enable telemetry data collection for NPM dependencies.
|
|
119
|
+
*/
|
|
31
120
|
dependencies?: null;
|
|
32
121
|
}
|
|
122
|
+
/**
|
|
123
|
+
* JSX scope configuration
|
|
124
|
+
*/
|
|
33
125
|
export interface JsxScopeConfig {
|
|
126
|
+
/**
|
|
127
|
+
* Enable telemetry data collection for JSX elements.
|
|
128
|
+
*/
|
|
34
129
|
elements?: ElementsConfig;
|
|
35
130
|
}
|
|
131
|
+
/**
|
|
132
|
+
* JavaScript scope configuration
|
|
133
|
+
*/
|
|
36
134
|
export interface JsScopeConfig {
|
|
135
|
+
/**
|
|
136
|
+
* Enable telemetry data collection for JS tokens.
|
|
137
|
+
*/
|
|
37
138
|
tokens?: null;
|
|
139
|
+
/**
|
|
140
|
+
* Enable telemetry data collection for JS functions.
|
|
141
|
+
*/
|
|
38
142
|
functions?: FunctionsConfig;
|
|
39
143
|
}
|
|
144
|
+
/**
|
|
145
|
+
* Web Components scope configuration
|
|
146
|
+
*/
|
|
40
147
|
export interface WcScopeConfig {
|
|
148
|
+
/**
|
|
149
|
+
* Enable telemetry data collection for Web Component elements.
|
|
150
|
+
*/
|
|
41
151
|
elements?: ElementsConfig;
|
|
42
152
|
}
|
|
153
|
+
/**
|
|
154
|
+
* Elements configuration for JSX and WC scopes
|
|
155
|
+
*/
|
|
43
156
|
export interface ElementsConfig {
|
|
157
|
+
/**
|
|
158
|
+
* Enable telemetry data collection for specific attribute names.
|
|
159
|
+
*/
|
|
44
160
|
allowedAttributeNames?: string[];
|
|
161
|
+
/**
|
|
162
|
+
* Enable telemetry data collection for specific attribute string values.
|
|
163
|
+
*/
|
|
45
164
|
allowedAttributeStringValues?: string[];
|
|
46
165
|
}
|
|
166
|
+
/**
|
|
167
|
+
* Functions configuration for JS scope
|
|
168
|
+
*/
|
|
47
169
|
export interface FunctionsConfig {
|
|
170
|
+
/**
|
|
171
|
+
* Enable telemetry data collection for specific string function argument values.
|
|
172
|
+
*/
|
|
48
173
|
allowedArgumentStringValues?: string[];
|
|
49
174
|
}
|
|
50
175
|
//# sourceMappingURL=config-schema.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-schema.d.ts","sourceRoot":"","sources":["../../src/main/config-schema.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"config-schema.d.ts","sourceRoot":"","sources":["../../src/main/config-schema.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AASH;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,OAAO,EAAE,CAAC,CAAC;IAEX;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,OAAO,EAAE,aAAa,CAAC;IAEvB;;OAEG;IACH,OAAO,EAAE,aAAa,CAAC;CACxB;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IAEzB;;OAEG;IACH,IAAI,CAAC,EAAE,iBAAiB,CAAC;IAEzB;;OAEG;IACH,OAAO,CAAC,EAAE,oBAAoB,CAAC;CAChC;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,QAAQ,CAAC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025
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/
|
|
1
9
|
export {};
|
|
2
10
|
//# sourceMappingURL=config-schema.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-schema.js","sourceRoot":"","sources":["../../src/main/config-schema.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"config-schema.js","sourceRoot":"","sources":["../../src/main/config-schema.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@octaviaflow/telemetry-config-schema",
|
|
3
3
|
"description": "Telemetry config schema for OctaviaFlow Telemetry",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.2",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "OctaviaFlow",
|
|
7
7
|
"keywords": [
|
|
@@ -15,14 +15,12 @@
|
|
|
15
15
|
"publishConfig": {
|
|
16
16
|
"access": "public"
|
|
17
17
|
},
|
|
18
|
-
"homepage": "https://github.com/OctaviaFlow/OctaviaFlow-Design-System#readme",
|
|
19
18
|
"repository": {
|
|
20
19
|
"type": "git",
|
|
21
|
-
"url": "
|
|
22
|
-
|
|
23
|
-
"bugs": {
|
|
24
|
-
"url": "https://github.com/OctaviaFlow/OctaviaFlow-Design-System/issues"
|
|
20
|
+
"url": "https://github.com/octaviaflow-design-system.git",
|
|
21
|
+
"directory": "packages/telemetry-config-schema"
|
|
25
22
|
},
|
|
23
|
+
"bugs": "https://github.com/octaviaflow-design-system/issues",
|
|
26
24
|
"type": "module",
|
|
27
25
|
"exports": {
|
|
28
26
|
".": {
|
|
@@ -40,8 +38,8 @@
|
|
|
40
38
|
"clean": "rimraf dist",
|
|
41
39
|
"lint": "eslint src --ext .ts,.js",
|
|
42
40
|
"lint:fix": "eslint src --ext .ts,.js --fix",
|
|
43
|
-
"format": "prettier --write src/**/*.
|
|
44
|
-
"format:check": "prettier --check src/**/*.
|
|
41
|
+
"format": "prettier --write 'src/**/*.ts'",
|
|
42
|
+
"format:check": "prettier --check 'src/**/*.ts'",
|
|
45
43
|
"test": "jest",
|
|
46
44
|
"test:watch": "jest --watch",
|
|
47
45
|
"prepare": "husky"
|
|
@@ -49,7 +47,10 @@
|
|
|
49
47
|
"devDependencies": {
|
|
50
48
|
"@commitlint/cli": "^19.8.1",
|
|
51
49
|
"@commitlint/config-conventional": "^19.8.1",
|
|
50
|
+
"@eslint/js": "^9.39.1",
|
|
52
51
|
"@types/node": "^20.19.8",
|
|
52
|
+
"@typescript-eslint/eslint-plugin": "^8.26.1",
|
|
53
|
+
"@typescript-eslint/parser": "^8.26.1",
|
|
53
54
|
"eslint": "^9.39.1",
|
|
54
55
|
"eslint-config-octaviaflow": "^2.0.0",
|
|
55
56
|
"husky": "^9.1.7",
|