@envelop/prometheus 6.3.2 → 6.3.3
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/index.js +7 -9
- package/index.mjs +7 -9
- package/package.json +3 -3
package/index.js
CHANGED
|
@@ -23,17 +23,15 @@ function createInternalContext(parseResult) {
|
|
|
23
23
|
if (parseResult === null) {
|
|
24
24
|
return null;
|
|
25
25
|
}
|
|
26
|
-
|
|
26
|
+
if (parseResult instanceof Error) {
|
|
27
27
|
return null;
|
|
28
28
|
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
};
|
|
36
|
-
}
|
|
29
|
+
const operation = getOperation(parseResult);
|
|
30
|
+
return {
|
|
31
|
+
document: parseResult,
|
|
32
|
+
operationName: ((_a = operation.name) === null || _a === void 0 ? void 0 : _a.value) || 'Anonymous',
|
|
33
|
+
operationType: operation.operation,
|
|
34
|
+
};
|
|
37
35
|
}
|
|
38
36
|
function createHistogram(options) {
|
|
39
37
|
return options;
|
package/index.mjs
CHANGED
|
@@ -19,17 +19,15 @@ function createInternalContext(parseResult) {
|
|
|
19
19
|
if (parseResult === null) {
|
|
20
20
|
return null;
|
|
21
21
|
}
|
|
22
|
-
|
|
22
|
+
if (parseResult instanceof Error) {
|
|
23
23
|
return null;
|
|
24
24
|
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
};
|
|
32
|
-
}
|
|
25
|
+
const operation = getOperation(parseResult);
|
|
26
|
+
return {
|
|
27
|
+
document: parseResult,
|
|
28
|
+
operationName: ((_a = operation.name) === null || _a === void 0 ? void 0 : _a.value) || 'Anonymous',
|
|
29
|
+
operationType: operation.operation,
|
|
30
|
+
};
|
|
33
31
|
}
|
|
34
32
|
function createHistogram(options) {
|
|
35
33
|
return options;
|
package/package.json
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@envelop/prometheus",
|
|
3
|
-
"version": "6.3.
|
|
3
|
+
"version": "6.3.3",
|
|
4
4
|
"sideEffects": false,
|
|
5
5
|
"peerDependencies": {
|
|
6
|
-
"@envelop/core": "^2.3.
|
|
6
|
+
"@envelop/core": "^2.3.3",
|
|
7
7
|
"graphql": "^14.0.0 || ^15.0.0 || ^16.0.0",
|
|
8
8
|
"prom-client": "^13 || ^14.0.0"
|
|
9
9
|
},
|
|
10
10
|
"repository": {
|
|
11
11
|
"type": "git",
|
|
12
|
-
"url": "https://github.com/
|
|
12
|
+
"url": "https://github.com/n1ru4l/envelop.git",
|
|
13
13
|
"directory": "packages/plugins/prometheus"
|
|
14
14
|
},
|
|
15
15
|
"author": "Dotan Simha <dotansimha@gmail.com>",
|