@cargolift-cdi/types 0.1.26 → 0.1.27
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/db/entities/diagnostic-latency.entity.d.ts +2 -1
- package/dist/db/entities/diagnostic-latency.entity.d.ts.map +1 -1
- package/dist/db/entities/diagnostic-latency.entity.js +6 -2
- package/dist/db/repository/diagnostic-latency-repository.service.d.ts +2 -2
- package/dist/db/repository/diagnostic-latency-repository.service.d.ts.map +1 -1
- package/dist/db/repository/diagnostic-latency-repository.service.js +2 -2
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"diagnostic-latency.entity.d.ts","sourceRoot":"","sources":["../../../src/db/entities/diagnostic-latency.entity.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,qBACa,iBAAiB;IAE5B,EAAE,EAAG,MAAM,CAAC;IAGZ,aAAa,EAAG,MAAM,CAAC;IAGvB,eAAe,EAAG,IAAI,CAAC;IAGvB,aAAa,EAAG,IAAI,CAAC;IAGrB,SAAS,EAAG,MAAM,CAAC;CACpB"}
|
|
1
|
+
{"version":3,"file":"diagnostic-latency.entity.d.ts","sourceRoot":"","sources":["../../../src/db/entities/diagnostic-latency.entity.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,qBACa,iBAAiB;IAE5B,EAAE,EAAG,MAAM,CAAC;IAGZ,MAAM,EAAG,MAAM,CAAC;IAGhB,aAAa,EAAG,MAAM,CAAC;IAGvB,eAAe,EAAG,IAAI,CAAC;IAGvB,aAAa,EAAG,IAAI,CAAC;IAGrB,SAAS,EAAG,MAAM,CAAC;CACpB"}
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { Column, Entity,
|
|
7
|
+
import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm';
|
|
8
8
|
/**
|
|
9
9
|
* Entidade de diagnóstico de latência.
|
|
10
10
|
* Armazena informações sobre a latência de operações, incluindo timestamps de início e fim,
|
|
@@ -12,14 +12,18 @@ import { Column, Entity, PrimaryColumn } from 'typeorm';
|
|
|
12
12
|
*/
|
|
13
13
|
let DiagnosticLatency = class DiagnosticLatency {
|
|
14
14
|
id;
|
|
15
|
+
testId;
|
|
15
16
|
correlationId;
|
|
16
17
|
timestamp_start;
|
|
17
18
|
timestamp_end;
|
|
18
19
|
latencyMs;
|
|
19
20
|
};
|
|
20
21
|
__decorate([
|
|
21
|
-
|
|
22
|
+
PrimaryGeneratedColumn({ type: 'int' })
|
|
22
23
|
], DiagnosticLatency.prototype, "id", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
Column({ type: 'varchar', length: 36 })
|
|
26
|
+
], DiagnosticLatency.prototype, "testId", void 0);
|
|
23
27
|
__decorate([
|
|
24
28
|
Column({ type: 'varchar', default: 36 })
|
|
25
29
|
], DiagnosticLatency.prototype, "correlationId", void 0);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Repository } from 'typeorm';
|
|
2
2
|
import { DiagnosticLatency } from '../entities/diagnostic-latency.entity.js';
|
|
3
3
|
/**
|
|
4
4
|
* Repositório de diagnóstico de latência.
|
|
@@ -14,6 +14,6 @@ export declare class DiagnosticLatencyRepositoryService {
|
|
|
14
14
|
* @param timestamp_start
|
|
15
15
|
* @returns
|
|
16
16
|
*/
|
|
17
|
-
create(id: string, correlation_id: string, timestamp_start: Date): Promise<
|
|
17
|
+
create(id: string, correlation_id: string, timestamp_start: Date): Promise<DiagnosticLatency>;
|
|
18
18
|
}
|
|
19
19
|
//# sourceMappingURL=diagnostic-latency-repository.service.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"diagnostic-latency-repository.service.d.ts","sourceRoot":"","sources":["../../../src/db/repository/diagnostic-latency-repository.service.ts"],"names":[],"mappings":"AAEA,OAAO,
|
|
1
|
+
{"version":3,"file":"diagnostic-latency-repository.service.d.ts","sourceRoot":"","sources":["../../../src/db/repository/diagnostic-latency-repository.service.ts"],"names":[],"mappings":"AAEA,OAAO,EAAgB,UAAU,EAAE,MAAM,SAAS,CAAC;AACnD,OAAO,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAC;AAE7E;;;GAGG;AACH,qBACa,kCAAkC;IAG3C,OAAO,CAAC,QAAQ,CAAC,IAAI;gBAAJ,IAAI,EAAE,UAAU,CAAC,iBAAiB,CAAC;IAGtD;;;;;;OAMG;IACG,MAAM,CACV,EAAE,EAAE,MAAM,EACV,cAAc,EAAE,MAAM,EACtB,eAAe,EAAE,IAAI,GACpB,OAAO,CAAC,iBAAiB,CAAC;CAe9B"}
|
|
@@ -29,13 +29,13 @@ let DiagnosticLatencyRepositoryService = class DiagnosticLatencyRepositoryServic
|
|
|
29
29
|
async create(id, correlation_id, timestamp_start) {
|
|
30
30
|
const now = new Date();
|
|
31
31
|
const entity = this.repo.create({
|
|
32
|
-
id,
|
|
32
|
+
testId: id,
|
|
33
33
|
correlationId: correlation_id,
|
|
34
34
|
timestamp_start,
|
|
35
35
|
timestamp_end: now,
|
|
36
36
|
latencyMs: now.getTime() - timestamp_start.getTime(),
|
|
37
37
|
});
|
|
38
|
-
return this.repo.
|
|
38
|
+
return this.repo.save(entity);
|
|
39
39
|
}
|
|
40
40
|
};
|
|
41
41
|
DiagnosticLatencyRepositoryService = __decorate([
|