@golemio/fcd 1.0.1-dev.423382545 → 1.0.1-dev.425924272
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.
|
@@ -11,6 +11,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.floatingCarDataRouter = void 0;
|
|
13
13
|
const express_1 = require("@golemio/core/dist/shared/express");
|
|
14
|
+
const monitoring_1 = require("@golemio/core/dist/monitoring");
|
|
14
15
|
const helpers_1 = require("@golemio/core/dist/input-gateway/helpers");
|
|
15
16
|
const FloatingCarDataController_1 = require("./FloatingCarDataController");
|
|
16
17
|
class FloatingCarDataRouter {
|
|
@@ -23,11 +24,13 @@ class FloatingCarDataRouter {
|
|
|
23
24
|
this.floatingCarData = (req, res, next) => __awaiter(this, void 0, void 0, function* () {
|
|
24
25
|
try {
|
|
25
26
|
yield this.floatingCarDataController.processData(req.body);
|
|
27
|
+
const numberOfRecords = (JSON.stringify(req.body.d2LogicalModel.payloadPublication.elaboratedData || {}).match(/basicData/g) || []).length;
|
|
26
28
|
const metrics = {
|
|
27
|
-
numberOfRecords
|
|
29
|
+
numberOfRecords,
|
|
28
30
|
req,
|
|
29
31
|
};
|
|
30
32
|
helpers_1.loggerEvents.emit(helpers_1.LoggerEventType.NumberOfRecords, metrics);
|
|
33
|
+
monitoring_1.metricsService.recordNumberOfRecords(req, numberOfRecords);
|
|
31
34
|
res.sendStatus(204);
|
|
32
35
|
}
|
|
33
36
|
catch (err) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FloatingCarDataRouter.js","sourceRoot":"","sources":["../../src/input-gateway/FloatingCarDataRouter.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAA4F;AAC5F,sEAKkD;AAClD,2EAA0E;AAE1E,MAAM,qBAAqB;IAKvB;QAJO,WAAM,GAAW,IAAA,gBA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CAAC,KAAK,CAAC,YAAY,CAAC,IAAI,EAAE,CAC5G,CAAC,MAAM,CAAC;gBAET,MAAM,OAAO,GAA8B;oBACvC,eAAe;oBACf,GAAG;iBACN,CAAC;gBACF,sBAAY,CAAC,IAAI,CAAC,yBAAe,CAAC,eAAe,EAAE,OAAO,CAAC,CAAC;gBAE5D,2BAAc,CAAC,qBAAqB,CAAC,GAAG,EAAE,eAAe,CAAC,CAAC;gBAE3D,GAAG,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC;aACvB;YAAC,OAAO,GAAG,EAAE;gBACV,IAAI,CAAC,GAAG,CAAC,CAAC;aACb;QACL,CAAC,CAAA,CAAC;QA3BE,IAAI,CAAC,UAAU,EAAE,CAAC;IACtB,CAAC;CA2BJ;AAED,MAAM,qBAAqB,GAAG,IAAI,qBAAqB,EAAE,CAAC,MAAM,CAAC;AAExD,sDAAqB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@golemio/fcd",
|
|
3
|
-
"version": "1.0.1-dev.
|
|
3
|
+
"version": "1.0.1-dev.425924272",
|
|
4
4
|
"description": "Golemio Floating Car Data Module",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"devDependencies": {
|
|
30
30
|
"@commitlint/cli": "^11.0.0",
|
|
31
31
|
"@commitlint/config-conventional": "^11.0.0",
|
|
32
|
-
"@golemio/core": "1.1.
|
|
32
|
+
"@golemio/core": "1.1.9-dev.425846246",
|
|
33
33
|
"@golemio/eslint-config": "^1.0.2",
|
|
34
34
|
"@golemio/schema-definitions": "2.0.21",
|
|
35
35
|
"@types/body-parser-xml": "^1.1.0",
|
package/CHANGELOG.md
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
All notable changes to this project will be documented in this file.
|
|
4
|
-
|
|
5
|
-
## [Unreleased]
|
|
6
|
-
|
|
7
|
-
## [1.0.1] - 2021-12-01
|
|
8
|
-
|
|
9
|
-
### Added
|
|
10
|
-
|
|
11
|
-
- Swagger doc
|
|
12
|
-
- Portman tests
|
|
13
|
-
|
|
14
|
-
## [1.0.0] - 2021-11-30
|
|
15
|
-
|
|
16
|
-
### Added
|
|
17
|
-
|
|
18
|
-
- Create the FCD module
|