@ludeo/cloud-common 1.2.18 → 1.2.19
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/tsconfig.tsbuildinfo +1 -1
- package/dist/v4/events/cloud-session-stats-report.d.ts +14 -2
- package/dist/v4/events/cloud-session-stats-report.js +38 -4
- package/dist/v4/events/cloud-session-stats-report.js.map +1 -1
- package/package.json +1 -1
- package/src/v4/events/cloud-session-stats-report.ts +29 -4
|
@@ -1,9 +1,21 @@
|
|
|
1
1
|
import { LudeoEvent } from "../../infra";
|
|
2
2
|
import { CloudSessionContext } from "../contexts";
|
|
3
|
-
export
|
|
3
|
+
export declare class RTCInboundRtpStreamStats {
|
|
4
|
+
jitter: number;
|
|
5
|
+
packetsReceived: number;
|
|
6
|
+
packetsLost: number;
|
|
7
|
+
}
|
|
8
|
+
export declare class RTCIceCandidatePairStats {
|
|
9
|
+
currentRoundTripTime: number;
|
|
10
|
+
}
|
|
11
|
+
export declare class CloudSessionStatsReportPayload {
|
|
12
|
+
inboundReport: RTCInboundRtpStreamStats;
|
|
13
|
+
candidatePairReport: RTCIceCandidatePairStats;
|
|
14
|
+
}
|
|
4
15
|
export declare class CloudSessionStatsReport extends LudeoEvent {
|
|
5
16
|
static readonly EVENT_NAME = "cloud-sessions.cloud-session-stats-report";
|
|
17
|
+
eventVersion: string;
|
|
6
18
|
constructor(payload: CloudSessionStatsReportPayload, context: CloudSessionContext);
|
|
7
|
-
payload:
|
|
19
|
+
payload: CloudSessionStatsReportPayload;
|
|
8
20
|
context: CloudSessionContext;
|
|
9
21
|
}
|
|
@@ -9,14 +9,48 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.CloudSessionStatsReport = void 0;
|
|
12
|
+
exports.CloudSessionStatsReport = exports.CloudSessionStatsReportPayload = exports.RTCIceCandidatePairStats = exports.RTCInboundRtpStreamStats = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
13
14
|
const infra_1 = require("../../infra");
|
|
14
15
|
const decorators_1 = require("../../decorators");
|
|
15
|
-
const types_1 = require("../types");
|
|
16
16
|
const contexts_1 = require("../contexts");
|
|
17
|
+
class RTCInboundRtpStreamStats {
|
|
18
|
+
}
|
|
19
|
+
exports.RTCInboundRtpStreamStats = RTCInboundRtpStreamStats;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, class_validator_1.IsNumber)(),
|
|
22
|
+
__metadata("design:type", Number)
|
|
23
|
+
], RTCInboundRtpStreamStats.prototype, "jitter", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_validator_1.IsNumber)(),
|
|
26
|
+
__metadata("design:type", Number)
|
|
27
|
+
], RTCInboundRtpStreamStats.prototype, "packetsReceived", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, class_validator_1.IsNumber)(),
|
|
30
|
+
__metadata("design:type", Number)
|
|
31
|
+
], RTCInboundRtpStreamStats.prototype, "packetsLost", void 0);
|
|
32
|
+
class RTCIceCandidatePairStats {
|
|
33
|
+
}
|
|
34
|
+
exports.RTCIceCandidatePairStats = RTCIceCandidatePairStats;
|
|
35
|
+
__decorate([
|
|
36
|
+
(0, class_validator_1.IsNumber)(),
|
|
37
|
+
__metadata("design:type", Number)
|
|
38
|
+
], RTCIceCandidatePairStats.prototype, "currentRoundTripTime", void 0);
|
|
39
|
+
class CloudSessionStatsReportPayload {
|
|
40
|
+
}
|
|
41
|
+
exports.CloudSessionStatsReportPayload = CloudSessionStatsReportPayload;
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, decorators_1.ValidateNestedType)(() => RTCInboundRtpStreamStats),
|
|
44
|
+
__metadata("design:type", RTCInboundRtpStreamStats)
|
|
45
|
+
], CloudSessionStatsReportPayload.prototype, "inboundReport", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, decorators_1.ValidateNestedType)(() => RTCIceCandidatePairStats),
|
|
48
|
+
__metadata("design:type", RTCIceCandidatePairStats)
|
|
49
|
+
], CloudSessionStatsReportPayload.prototype, "candidatePairReport", void 0);
|
|
17
50
|
class CloudSessionStatsReport extends infra_1.LudeoEvent {
|
|
18
51
|
constructor(payload, context) {
|
|
19
52
|
super(CloudSessionStatsReport.EVENT_NAME);
|
|
53
|
+
this.eventVersion = "4.0";
|
|
20
54
|
this.payload = payload;
|
|
21
55
|
this.context = context;
|
|
22
56
|
}
|
|
@@ -24,8 +58,8 @@ class CloudSessionStatsReport extends infra_1.LudeoEvent {
|
|
|
24
58
|
exports.CloudSessionStatsReport = CloudSessionStatsReport;
|
|
25
59
|
CloudSessionStatsReport.EVENT_NAME = "cloud-sessions.cloud-session-stats-report";
|
|
26
60
|
__decorate([
|
|
27
|
-
(0, decorators_1.ValidateNestedType)(() =>
|
|
28
|
-
__metadata("design:type",
|
|
61
|
+
(0, decorators_1.ValidateNestedType)(() => CloudSessionStatsReportPayload),
|
|
62
|
+
__metadata("design:type", CloudSessionStatsReportPayload)
|
|
29
63
|
], CloudSessionStatsReport.prototype, "payload", void 0);
|
|
30
64
|
__decorate([
|
|
31
65
|
(0, decorators_1.ValidateNestedType)(() => contexts_1.CloudSessionContext),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cloud-session-stats-report.js","sourceRoot":"","sources":["../../../src/v4/events/cloud-session-stats-report.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,uCAAyC;AACzC,iDAAsD;AACtD,
|
|
1
|
+
{"version":3,"file":"cloud-session-stats-report.js","sourceRoot":"","sources":["../../../src/v4/events/cloud-session-stats-report.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA2C;AAE3C,uCAAyC;AACzC,iDAAsD;AACtD,0CAAkD;AAElD,MAAa,wBAAwB;CASpC;AATD,4DASC;AAPC;IADC,IAAA,0BAAQ,GAAE;;wDACI;AAGf;IADC,IAAA,0BAAQ,GAAE;;iEACa;AAGxB;IADC,IAAA,0BAAQ,GAAE;;6DACS;AAGtB,MAAa,wBAAwB;CAGpC;AAHD,4DAGC;AADC;IADC,IAAA,0BAAQ,GAAE;;sEACkB;AAG/B,MAAa,8BAA8B;CAM1C;AAND,wEAMC;AAJC;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,wBAAwB,CAAC;8BACpC,wBAAwB;qEAAC;AAGxC;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,wBAAwB,CAAC;8BAC9B,wBAAwB;2EAAC;AAGhD,MAAa,uBAAwB,SAAQ,kBAAU;IAIrD,YACE,OAAuC,EACvC,OAA4B;QAE5B,KAAK,CAAC,uBAAuB,CAAC,UAAU,CAAC,CAAC;QAN5C,iBAAY,GAAG,KAAK,CAAC;QAOnB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAXH,0DAkBC;AAjBiB,kCAAU,GAAG,2CAA2C,AAA9C,CAA+C;AAazE;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,8BAA8B,CAAC;8BAChD,8BAA8B;wDAAC;AAGxC;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,8BAAmB,CAAC;8BACrC,8BAAmB;wDAAC"}
|
package/package.json
CHANGED
|
@@ -1,11 +1,36 @@
|
|
|
1
|
+
import { IsNumber } from "class-validator";
|
|
2
|
+
|
|
1
3
|
import { LudeoEvent } from "../../infra";
|
|
2
4
|
import { ValidateNestedType } from "../../decorators";
|
|
3
|
-
import { CloudSession } from "../types";
|
|
4
5
|
import { CloudSessionContext } from "../contexts";
|
|
5
6
|
|
|
6
|
-
export
|
|
7
|
+
export class RTCInboundRtpStreamStats {
|
|
8
|
+
@IsNumber()
|
|
9
|
+
jitter: number;
|
|
10
|
+
|
|
11
|
+
@IsNumber()
|
|
12
|
+
packetsReceived: number;
|
|
13
|
+
|
|
14
|
+
@IsNumber()
|
|
15
|
+
packetsLost: number;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export class RTCIceCandidatePairStats {
|
|
19
|
+
@IsNumber()
|
|
20
|
+
currentRoundTripTime: number;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export class CloudSessionStatsReportPayload {
|
|
24
|
+
@ValidateNestedType(() => RTCInboundRtpStreamStats)
|
|
25
|
+
inboundReport: RTCInboundRtpStreamStats;
|
|
26
|
+
|
|
27
|
+
@ValidateNestedType(() => RTCIceCandidatePairStats)
|
|
28
|
+
candidatePairReport: RTCIceCandidatePairStats;
|
|
29
|
+
}
|
|
30
|
+
|
|
7
31
|
export class CloudSessionStatsReport extends LudeoEvent {
|
|
8
32
|
static readonly EVENT_NAME = "cloud-sessions.cloud-session-stats-report";
|
|
33
|
+
eventVersion = "4.0";
|
|
9
34
|
|
|
10
35
|
constructor(
|
|
11
36
|
payload: CloudSessionStatsReportPayload,
|
|
@@ -16,8 +41,8 @@ export class CloudSessionStatsReport extends LudeoEvent {
|
|
|
16
41
|
this.context = context;
|
|
17
42
|
}
|
|
18
43
|
|
|
19
|
-
@ValidateNestedType(() =>
|
|
20
|
-
payload:
|
|
44
|
+
@ValidateNestedType(() => CloudSessionStatsReportPayload)
|
|
45
|
+
payload: CloudSessionStatsReportPayload;
|
|
21
46
|
|
|
22
47
|
@ValidateNestedType(() => CloudSessionContext)
|
|
23
48
|
context: CloudSessionContext;
|