@webex/internal-plugin-metrics 3.12.0-mobius-socket.2 → 3.12.0-mobius-socket.4
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/call-diagnostic/call-diagnostic-metrics-latencies.js +68 -51
- package/dist/call-diagnostic/call-diagnostic-metrics-latencies.js.map +1 -1
- package/dist/call-diagnostic/call-diagnostic-metrics.js +7 -2
- package/dist/call-diagnostic/call-diagnostic-metrics.js.map +1 -1
- package/dist/call-diagnostic/call-diagnostic-metrics.util.js +2 -2
- package/dist/call-diagnostic/call-diagnostic-metrics.util.js.map +1 -1
- package/dist/call-diagnostic/config.js +2 -1
- package/dist/call-diagnostic/config.js.map +1 -1
- package/dist/metrics.js +1 -1
- package/dist/metrics.types.js.map +1 -1
- package/dist/types/call-diagnostic/call-diagnostic-metrics-latencies.d.ts +9 -0
- package/dist/types/call-diagnostic/call-diagnostic-metrics.d.ts +16 -13
- package/dist/types/metrics.types.d.ts +2 -2
- package/package.json +11 -11
- package/src/call-diagnostic/call-diagnostic-metrics-latencies.ts +140 -69
- package/src/call-diagnostic/call-diagnostic-metrics.ts +6 -0
- package/src/call-diagnostic/call-diagnostic-metrics.util.ts +2 -1
- package/src/call-diagnostic/config.ts +1 -0
- package/src/metrics.types.ts +1 -1
- package/test/unit/spec/call-diagnostic/call-diagnostic-metrics-batcher.ts +14 -2
- package/test/unit/spec/call-diagnostic/call-diagnostic-metrics-latencies.ts +243 -288
- package/test/unit/spec/call-diagnostic/call-diagnostic-metrics.ts +403 -157
|
@@ -42,7 +42,7 @@ export type SubmitMQEOptions = {
|
|
|
42
42
|
globalMeetingId?: string;
|
|
43
43
|
};
|
|
44
44
|
export type InternalEvent = {
|
|
45
|
-
name: 'internal.client.meetinginfo.request' | 'internal.client.meetinginfo.response' | 'internal.register.device.request' | 'internal.register.device.response' | 'internal.reset.join.latencies' | 'internal.
|
|
45
|
+
name: 'internal.client.meetinginfo.request' | 'internal.client.meetinginfo.response' | 'internal.register.device.request' | 'internal.register.device.response' | 'internal.reset.join.latencies' | 'internal.host.meeting.participant.admitted' | 'internal.client.meeting.interstitial-window.showed' | 'internal.client.interstitial-window.click.joinbutton' | 'internal.client.add-media.turn-discovery.start' | 'internal.client.add-media.turn-discovery.end' | 'internal.client.share.initiated' | 'internal.client.share.stopped';
|
|
46
46
|
payload?: never;
|
|
47
47
|
options?: never;
|
|
48
48
|
};
|
|
@@ -154,7 +154,7 @@ export type BuildClientEventFetchRequestOptions = (args: {
|
|
|
154
154
|
payload?: RecursivePartial<ClientEvent['payload']>;
|
|
155
155
|
options?: SubmitClientEventOptions;
|
|
156
156
|
}) => Promise<any>;
|
|
157
|
-
export type PreComputedLatencies = 'internal.client.pageJMT' | 'internal.download.time' | 'internal.get.cluster.time' | 'internal.click.to.interstitial' | 'internal.click.to.interstitial.with.user.delay' | 'internal.refresh.captcha.time' | 'internal.exchange.ci.token.time' | 'internal.get.u2c.time' | 'internal.call.init.join.req' | 'internal.other.app.api.time' | 'internal.api.fetch.intelligence.models';
|
|
157
|
+
export type PreComputedLatencies = 'internal.client.pageJMT' | 'internal.download.time' | 'internal.get.cluster.time' | 'internal.click.to.interstitial' | 'internal.click.to.interstitial.with.user.delay' | 'internal.click.to.interstitial.for.client.jmt' | 'internal.refresh.captcha.time' | 'internal.exchange.ci.token.time' | 'internal.get.u2c.time' | 'internal.call.init.join.req' | 'internal.other.app.api.time' | 'internal.api.fetch.intelligence.models';
|
|
158
158
|
export interface IdType {
|
|
159
159
|
meetingId?: string;
|
|
160
160
|
callId?: string;
|
package/package.json
CHANGED
|
@@ -24,23 +24,23 @@
|
|
|
24
24
|
"@sinonjs/fake-timers": "^6.0.1",
|
|
25
25
|
"@webex/babel-config-legacy": "0.0.0",
|
|
26
26
|
"@webex/eslint-config-legacy": "0.0.0",
|
|
27
|
-
"@webex/event-dictionary-ts": "^1.0.
|
|
27
|
+
"@webex/event-dictionary-ts": "^1.0.2138",
|
|
28
28
|
"@webex/jest-config-legacy": "0.0.0",
|
|
29
29
|
"@webex/legacy-tools": "0.0.0",
|
|
30
|
-
"@webex/test-helper-chai": "3.12.0-mobius-socket.
|
|
31
|
-
"@webex/test-helper-mocha": "3.12.0-mobius-socket.
|
|
32
|
-
"@webex/test-helper-mock-webex": "3.12.0-mobius-socket.
|
|
33
|
-
"@webex/test-helper-test-users": "3.12.0-mobius-socket.
|
|
30
|
+
"@webex/test-helper-chai": "3.12.0-mobius-socket.3",
|
|
31
|
+
"@webex/test-helper-mocha": "3.12.0-mobius-socket.3",
|
|
32
|
+
"@webex/test-helper-mock-webex": "3.12.0-mobius-socket.3",
|
|
33
|
+
"@webex/test-helper-test-users": "3.12.0-mobius-socket.3",
|
|
34
34
|
"eslint": "^8.24.0",
|
|
35
35
|
"prettier": "^2.7.1",
|
|
36
36
|
"sinon": "^9.2.4"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@webex/common": "3.12.0-mobius-socket.
|
|
40
|
-
"@webex/common-timers": "3.12.0-mobius-socket.
|
|
41
|
-
"@webex/test-helper-chai": "3.12.0-mobius-socket.
|
|
42
|
-
"@webex/test-helper-mock-webex": "3.12.0-mobius-socket.
|
|
43
|
-
"@webex/webex-core": "3.12.0-mobius-socket.
|
|
39
|
+
"@webex/common": "3.12.0-mobius-socket.3",
|
|
40
|
+
"@webex/common-timers": "3.12.0-mobius-socket.3",
|
|
41
|
+
"@webex/test-helper-chai": "3.12.0-mobius-socket.3",
|
|
42
|
+
"@webex/test-helper-mock-webex": "3.12.0-mobius-socket.3",
|
|
43
|
+
"@webex/webex-core": "3.12.0-mobius-socket.4",
|
|
44
44
|
"ip-anonymize": "^0.1.0",
|
|
45
45
|
"lodash": "^4.17.21",
|
|
46
46
|
"uuid": "^3.3.2"
|
|
@@ -53,5 +53,5 @@
|
|
|
53
53
|
"test:style": "eslint ./src/**/*.*",
|
|
54
54
|
"test:unit": "webex-legacy-tools test --unit --runner mocha"
|
|
55
55
|
},
|
|
56
|
-
"version": "3.12.0-mobius-socket.
|
|
56
|
+
"version": "3.12.0-mobius-socket.4"
|
|
57
57
|
}
|
|
@@ -193,7 +193,7 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
193
193
|
*/
|
|
194
194
|
public getShowInterstitialTime() {
|
|
195
195
|
return this.getDiffBetweenTimestamps(
|
|
196
|
-
'client.interstitial-window.
|
|
196
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
197
197
|
'internal.client.interstitial-window.click.joinbutton'
|
|
198
198
|
);
|
|
199
199
|
}
|
|
@@ -224,11 +224,17 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
224
224
|
* @returns - latency
|
|
225
225
|
*/
|
|
226
226
|
public getCallInitJoinReq() {
|
|
227
|
-
|
|
228
|
-
'internal.client.interstitial-window.
|
|
229
|
-
'client.locus.join.request'
|
|
230
|
-
{maximum: 1200000}
|
|
227
|
+
const interstitialShowedToJoinReq = this.getDiffBetweenTimestamps(
|
|
228
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
229
|
+
'client.locus.join.request'
|
|
231
230
|
);
|
|
231
|
+
const showInterstitialTime = this.getShowInterstitialTime() || 0;
|
|
232
|
+
|
|
233
|
+
if (typeof interstitialShowedToJoinReq !== 'number') {
|
|
234
|
+
return undefined;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
return clamp(interstitialShowedToJoinReq - showInterstitialTime, 0, 1200000);
|
|
232
238
|
}
|
|
233
239
|
|
|
234
240
|
/**
|
|
@@ -303,7 +309,39 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
303
309
|
* @returns - latency
|
|
304
310
|
*/
|
|
305
311
|
public getStayLobbyTime() {
|
|
306
|
-
return this.getDiffBetweenTimestamps('client.
|
|
312
|
+
return this.getDiffBetweenTimestamps('client.lobby.entered', 'client.lobby.exited');
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
/**
|
|
316
|
+
* Stay lobby time capped by a certain timestamp.
|
|
317
|
+
* This is to handle the case where the target end timestamp could happen before the lobby is exited,
|
|
318
|
+
* for example media-engine.ready or client.ice.end
|
|
319
|
+
* This is supposed to be called AFTER the end timestamp happens
|
|
320
|
+
* @param endTimestampKey name of the target end event
|
|
321
|
+
* @returns - latency
|
|
322
|
+
*/
|
|
323
|
+
public getStayLobbyTimeCappedBy(endTimestampKey: MetricEventNames) {
|
|
324
|
+
const lobbyStartTimestamp = this.latencyTimestamps.get('client.lobby.entered'); // might not exist (some meetings don't have lobby)
|
|
325
|
+
|
|
326
|
+
if (typeof lobbyStartTimestamp !== 'number') {
|
|
327
|
+
// no lobby in the meeting, stayLobbyTime is 0
|
|
328
|
+
return 0;
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
const lobbyEndTimestamp = this.latencyTimestamps.get('client.lobby.exited'); // might not exist (if user still in lobby at the time of measurement)
|
|
332
|
+
const maximumEndTimestamp = this.latencyTimestamps.get(endTimestampKey); // must exist
|
|
333
|
+
|
|
334
|
+
if (typeof maximumEndTimestamp !== 'number') {
|
|
335
|
+
// the provided timestamp to be used as a cap should exist, return undefined if it doesn't
|
|
336
|
+
return undefined;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
const endTimestamp =
|
|
340
|
+
typeof lobbyEndTimestamp === 'number'
|
|
341
|
+
? Math.min(lobbyEndTimestamp, maximumEndTimestamp)
|
|
342
|
+
: maximumEndTimestamp;
|
|
343
|
+
|
|
344
|
+
return clamp(endTimestamp - lobbyStartTimestamp, 0, this.MAX_INTEGER);
|
|
307
345
|
}
|
|
308
346
|
|
|
309
347
|
/**
|
|
@@ -331,14 +369,6 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
331
369
|
* @returns - latency
|
|
332
370
|
*/
|
|
333
371
|
public getClickToInterstitial() {
|
|
334
|
-
// for normal join (where green join button exists before interstitial, i.e reminder, space list etc)
|
|
335
|
-
if (this.latencyTimestamps.get('internal.client.meeting.click.joinbutton')) {
|
|
336
|
-
return this.getDiffBetweenTimestamps(
|
|
337
|
-
'internal.client.meeting.click.joinbutton',
|
|
338
|
-
'internal.client.meeting.interstitial-window.showed'
|
|
339
|
-
);
|
|
340
|
-
}
|
|
341
|
-
|
|
342
372
|
const clickToInterstitialLatency = this.precomputedLatencies.get(
|
|
343
373
|
'internal.click.to.interstitial'
|
|
344
374
|
);
|
|
@@ -355,14 +385,6 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
355
385
|
* @returns - latency
|
|
356
386
|
*/
|
|
357
387
|
public getClickToInterstitialWithUserDelay() {
|
|
358
|
-
// for normal join (where green join button exists before interstitial, i.e reminder, space list etc)
|
|
359
|
-
if (this.latencyTimestamps.get('internal.client.meeting.click.joinbutton')) {
|
|
360
|
-
return this.getDiffBetweenTimestamps(
|
|
361
|
-
'internal.client.meeting.click.joinbutton',
|
|
362
|
-
'internal.client.meeting.interstitial-window.showed'
|
|
363
|
-
);
|
|
364
|
-
}
|
|
365
|
-
|
|
366
388
|
const clickToInterstitialWithUserDelayLatency = this.precomputedLatencies.get(
|
|
367
389
|
'internal.click.to.interstitial.with.user.delay'
|
|
368
390
|
);
|
|
@@ -379,10 +401,17 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
379
401
|
* @returns - latency
|
|
380
402
|
*/
|
|
381
403
|
public getInterstitialToJoinOK() {
|
|
382
|
-
|
|
383
|
-
'internal.client.interstitial-window.
|
|
404
|
+
const interstitialShowedToJoinResp = this.getDiffBetweenTimestamps(
|
|
405
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
384
406
|
'client.locus.join.response'
|
|
385
407
|
);
|
|
408
|
+
const showInterstitialTime = this.getShowInterstitialTime() || 0;
|
|
409
|
+
|
|
410
|
+
if (typeof interstitialShowedToJoinResp !== 'number') {
|
|
411
|
+
return undefined;
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
return clamp(interstitialShowedToJoinResp - showInterstitialTime, 0, this.MAX_INTEGER);
|
|
386
415
|
}
|
|
387
416
|
|
|
388
417
|
/**
|
|
@@ -390,11 +419,7 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
390
419
|
* @returns - latency
|
|
391
420
|
*/
|
|
392
421
|
public getCallInitMediaEngineReady() {
|
|
393
|
-
return this.
|
|
394
|
-
'internal.client.interstitial-window.click.joinbutton',
|
|
395
|
-
'client.media-engine.ready',
|
|
396
|
-
{maximum: 1200000}
|
|
397
|
-
);
|
|
422
|
+
return this.getInterstitialToMediaOKJMT();
|
|
398
423
|
}
|
|
399
424
|
|
|
400
425
|
/**
|
|
@@ -402,20 +427,22 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
402
427
|
* @returns - latency
|
|
403
428
|
*/
|
|
404
429
|
public getInterstitialToMediaOKJMT() {
|
|
405
|
-
const
|
|
406
|
-
'internal.client.interstitial-window.
|
|
430
|
+
const interstitialShowedToIceEnd = this.getDiffBetweenTimestamps(
|
|
431
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
432
|
+
'client.ice.end'
|
|
407
433
|
);
|
|
434
|
+
const showInterstitialTime = this.getShowInterstitialTime() || 0;
|
|
435
|
+
const stayLobbyTimeCappedByIceEnd = this.getStayLobbyTimeCappedBy('client.ice.end');
|
|
408
436
|
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
return clamp(interstitialToMediaOKJmt, 0, this.MAX_INTEGER);
|
|
437
|
+
if (
|
|
438
|
+
typeof interstitialShowedToIceEnd === 'number' &&
|
|
439
|
+
typeof stayLobbyTimeCappedByIceEnd === 'number'
|
|
440
|
+
) {
|
|
441
|
+
return clamp(
|
|
442
|
+
interstitialShowedToIceEnd - showInterstitialTime - stayLobbyTimeCappedByIceEnd,
|
|
443
|
+
0,
|
|
444
|
+
this.MAX_INTEGER
|
|
445
|
+
);
|
|
419
446
|
}
|
|
420
447
|
|
|
421
448
|
return undefined;
|
|
@@ -427,10 +454,21 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
427
454
|
*/
|
|
428
455
|
public getTotalJMT() {
|
|
429
456
|
const clickToInterstitial = this.getClickToInterstitial();
|
|
430
|
-
const
|
|
457
|
+
const interstitialShowedToJoinLocusResponse = this.getDiffBetweenTimestamps(
|
|
458
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
459
|
+
'client.locus.join.response'
|
|
460
|
+
);
|
|
461
|
+
const showInterstitialTime = this.getShowInterstitialTime() || 0;
|
|
431
462
|
|
|
432
|
-
if (
|
|
433
|
-
|
|
463
|
+
if (
|
|
464
|
+
typeof clickToInterstitial === 'number' &&
|
|
465
|
+
typeof interstitialShowedToJoinLocusResponse === 'number'
|
|
466
|
+
) {
|
|
467
|
+
return clamp(
|
|
468
|
+
clickToInterstitial + interstitialShowedToJoinLocusResponse - showInterstitialTime,
|
|
469
|
+
0,
|
|
470
|
+
this.MAX_INTEGER
|
|
471
|
+
);
|
|
434
472
|
}
|
|
435
473
|
|
|
436
474
|
return undefined;
|
|
@@ -442,13 +480,20 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
442
480
|
*/
|
|
443
481
|
public getTotalJMTWithUserDelay() {
|
|
444
482
|
const clickToInterstitialWithUserDelay = this.getClickToInterstitialWithUserDelay();
|
|
445
|
-
const
|
|
483
|
+
const interstitialShowedToJoinLocusResponse = this.getDiffBetweenTimestamps(
|
|
484
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
485
|
+
'client.locus.join.response'
|
|
486
|
+
);
|
|
446
487
|
|
|
447
488
|
if (
|
|
448
489
|
typeof clickToInterstitialWithUserDelay === 'number' &&
|
|
449
|
-
typeof
|
|
490
|
+
typeof interstitialShowedToJoinLocusResponse === 'number'
|
|
450
491
|
) {
|
|
451
|
-
return clamp(
|
|
492
|
+
return clamp(
|
|
493
|
+
clickToInterstitialWithUserDelay + interstitialShowedToJoinLocusResponse,
|
|
494
|
+
0,
|
|
495
|
+
this.MAX_INTEGER
|
|
496
|
+
);
|
|
452
497
|
}
|
|
453
498
|
|
|
454
499
|
return undefined;
|
|
@@ -475,22 +520,28 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
475
520
|
*/
|
|
476
521
|
public getTotalMediaJMT() {
|
|
477
522
|
const clickToInterstitial = this.getClickToInterstitial();
|
|
478
|
-
const
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
523
|
+
const interstitialShowedToMediaEngineReady = this.getDiffBetweenTimestamps(
|
|
524
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
525
|
+
'client.media-engine.ready'
|
|
526
|
+
);
|
|
527
|
+
const showInterstitialTime = this.getShowInterstitialTime() || 0;
|
|
528
|
+
const stayLobbyTimeCappedByMediaEngineReady = this.getStayLobbyTimeCappedBy(
|
|
529
|
+
'client.media-engine.ready'
|
|
530
|
+
);
|
|
531
|
+
|
|
532
|
+
if (
|
|
533
|
+
typeof clickToInterstitial === 'number' &&
|
|
534
|
+
typeof interstitialShowedToMediaEngineReady === 'number' &&
|
|
535
|
+
typeof stayLobbyTimeCappedByMediaEngineReady === 'number'
|
|
536
|
+
) {
|
|
537
|
+
return clamp(
|
|
538
|
+
clickToInterstitial +
|
|
539
|
+
interstitialShowedToMediaEngineReady -
|
|
540
|
+
showInterstitialTime -
|
|
541
|
+
stayLobbyTimeCappedByMediaEngineReady,
|
|
486
542
|
0,
|
|
487
|
-
|
|
543
|
+
this.MAX_INTEGER
|
|
488
544
|
);
|
|
489
|
-
if (this.getMeeting()?.allowMediaInLobby) {
|
|
490
|
-
return clamp(totalMediaJMT, 0, this.MAX_INTEGER);
|
|
491
|
-
}
|
|
492
|
-
|
|
493
|
-
return clamp(totalMediaJMT - lobbyTime, 0, this.MAX_INTEGER);
|
|
494
545
|
}
|
|
495
546
|
|
|
496
547
|
return undefined;
|
|
@@ -502,12 +553,17 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
502
553
|
*/
|
|
503
554
|
public getTotalMediaJMTWithUserDelay() {
|
|
504
555
|
const clickToInterstitialWithUserDelay = this.getClickToInterstitialWithUserDelay();
|
|
505
|
-
const
|
|
506
|
-
|
|
556
|
+
const interstitialShowedToMediaEngineReady = this.getDiffBetweenTimestamps(
|
|
557
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
558
|
+
'client.media-engine.ready'
|
|
559
|
+
);
|
|
507
560
|
|
|
508
|
-
if (
|
|
561
|
+
if (
|
|
562
|
+
typeof clickToInterstitialWithUserDelay === 'number' &&
|
|
563
|
+
typeof interstitialShowedToMediaEngineReady === 'number'
|
|
564
|
+
) {
|
|
509
565
|
return clamp(
|
|
510
|
-
clickToInterstitialWithUserDelay +
|
|
566
|
+
clickToInterstitialWithUserDelay + interstitialShowedToMediaEngineReady,
|
|
511
567
|
0,
|
|
512
568
|
this.MAX_INTEGER
|
|
513
569
|
);
|
|
@@ -521,11 +577,26 @@ export default class CallDiagnosticLatencies extends WebexPlugin {
|
|
|
521
577
|
* @returns - latency
|
|
522
578
|
*/
|
|
523
579
|
public getClientJMT() {
|
|
524
|
-
const
|
|
525
|
-
|
|
580
|
+
const clickToInterstitialForClientJmt = this.precomputedLatencies.get(
|
|
581
|
+
'internal.click.to.interstitial.for.client.jmt'
|
|
582
|
+
);
|
|
583
|
+
const interstitialShowedToLocusJoinRequest = this.getDiffBetweenTimestamps(
|
|
584
|
+
'internal.client.meeting.interstitial-window.showed',
|
|
585
|
+
'client.locus.join.request'
|
|
586
|
+
);
|
|
587
|
+
const showInterstitialTime = this.getShowInterstitialTime() || 0;
|
|
526
588
|
|
|
527
|
-
if (
|
|
528
|
-
|
|
589
|
+
if (
|
|
590
|
+
typeof clickToInterstitialForClientJmt === 'number' &&
|
|
591
|
+
typeof interstitialShowedToLocusJoinRequest === 'number'
|
|
592
|
+
) {
|
|
593
|
+
return clamp(
|
|
594
|
+
clickToInterstitialForClientJmt +
|
|
595
|
+
interstitialShowedToLocusJoinRequest -
|
|
596
|
+
showInterstitialTime,
|
|
597
|
+
0,
|
|
598
|
+
this.MAX_INTEGER
|
|
599
|
+
);
|
|
529
600
|
}
|
|
530
601
|
|
|
531
602
|
return undefined;
|
|
@@ -190,6 +190,11 @@ export default class CallDiagnosticMetrics extends StatelessWebexPlugin {
|
|
|
190
190
|
|
|
191
191
|
// if ConvergedArchitecture enable and isConvergedWebinarWebcast -- then webcast
|
|
192
192
|
if (meetingInfo?.enableConvergedArchitecture && meetingInfo?.enableEvent) {
|
|
193
|
+
// if enableConvergedWebinarLargeScale - then large scale webinar
|
|
194
|
+
if (meetingInfo?.enableConvergedWebinarLargeScale) {
|
|
195
|
+
return WEBEX_SUB_SERVICE_TYPES.LARGE_SCALE_WEBINAR;
|
|
196
|
+
}
|
|
197
|
+
|
|
193
198
|
return meetingInfo?.isConvergedWebinarWebcast
|
|
194
199
|
? WEBEX_SUB_SERVICE_TYPES.WEBCAST
|
|
195
200
|
: WEBEX_SUB_SERVICE_TYPES.WEBINAR;
|
|
@@ -1005,6 +1010,7 @@ export default class CallDiagnosticMetrics extends StatelessWebexPlugin {
|
|
|
1005
1010
|
webexSubServiceType: this.getSubServiceType(meeting),
|
|
1006
1011
|
// @ts-ignore
|
|
1007
1012
|
webClientPreload: this.webex.meetings?.config?.metrics?.webClientPreload,
|
|
1013
|
+
isVipMeeting: meeting?.meetingInfo?.vipmeeting || false,
|
|
1008
1014
|
};
|
|
1009
1015
|
|
|
1010
1016
|
const joinFlowVersion = options.joinFlowVersion ?? meeting.callStateForMetrics?.joinFlowVersion;
|
|
@@ -284,7 +284,8 @@ export const prepareDiagnosticMetricItem = (webex: any, item: any) => {
|
|
|
284
284
|
devicePairingType: webex.devicemanager.getPairedMethod(),
|
|
285
285
|
deviceURL: pairedDevice.url,
|
|
286
286
|
isPersonalDevice: pairedDevice.mode === 'personal',
|
|
287
|
-
productName:
|
|
287
|
+
productName:
|
|
288
|
+
pairedDevice.devices?.length > 0 ? pairedDevice.devices[0]?.productName : undefined,
|
|
288
289
|
};
|
|
289
290
|
item.eventPayload.event.pairingState = 'paired';
|
|
290
291
|
item.eventPayload.event.pairedDevice = devicePayload;
|
|
@@ -26,6 +26,7 @@ export const WEBEX_SUB_SERVICE_TYPES: Record<string, ClientSubServiceType> = {
|
|
|
26
26
|
SCHEDULED_MEETING: 'ScheduledMeeting',
|
|
27
27
|
WEBINAR: 'Webinar',
|
|
28
28
|
WEBCAST: 'Webcast',
|
|
29
|
+
LARGE_SCALE_WEBINAR: 'LargeScaleWebinar',
|
|
29
30
|
};
|
|
30
31
|
|
|
31
32
|
// Found in https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia
|
package/src/metrics.types.ts
CHANGED
|
@@ -156,7 +156,6 @@ export type InternalEvent = {
|
|
|
156
156
|
| 'internal.register.device.request'
|
|
157
157
|
| 'internal.register.device.response'
|
|
158
158
|
| 'internal.reset.join.latencies'
|
|
159
|
-
| 'internal.client.meeting.click.joinbutton'
|
|
160
159
|
| 'internal.host.meeting.participant.admitted'
|
|
161
160
|
| 'internal.client.meeting.interstitial-window.showed'
|
|
162
161
|
| 'internal.client.interstitial-window.click.joinbutton'
|
|
@@ -319,6 +318,7 @@ export type PreComputedLatencies =
|
|
|
319
318
|
| 'internal.get.cluster.time'
|
|
320
319
|
| 'internal.click.to.interstitial'
|
|
321
320
|
| 'internal.click.to.interstitial.with.user.delay'
|
|
321
|
+
| 'internal.click.to.interstitial.for.client.jmt'
|
|
322
322
|
| 'internal.refresh.captcha.time'
|
|
323
323
|
| 'internal.exchange.ci.token.time'
|
|
324
324
|
| 'internal.get.u2c.time'
|
|
@@ -192,6 +192,12 @@ describe('plugin-metrics', () => {
|
|
|
192
192
|
webex.internal.newMetrics.callDiagnosticLatencies.getTotalJMTWithUserDelay = sinon
|
|
193
193
|
.stub()
|
|
194
194
|
.returns(64);
|
|
195
|
+
webex.internal.newMetrics.callDiagnosticLatencies.getInterstitialToJoinOK = sinon
|
|
196
|
+
.stub()
|
|
197
|
+
.returns(10);
|
|
198
|
+
webex.internal.newMetrics.callDiagnosticLatencies.getTotalJMT = sinon
|
|
199
|
+
.stub()
|
|
200
|
+
.returns(20);
|
|
195
201
|
const promise = webex.internal.newMetrics.callDiagnosticMetrics.submitToCallDiagnostics(
|
|
196
202
|
//@ts-ignore
|
|
197
203
|
{event: {name: 'client.locus.join.response'}}
|
|
@@ -346,6 +352,12 @@ describe('plugin-metrics', () => {
|
|
|
346
352
|
webex.internal.newMetrics.callDiagnosticLatencies.getStayLobbyTime = sinon
|
|
347
353
|
.stub()
|
|
348
354
|
.returns(1);
|
|
355
|
+
webex.internal.newMetrics.callDiagnosticLatencies.getStayLobbyTimeCappedBy = sinon
|
|
356
|
+
.stub()
|
|
357
|
+
.returns(1);
|
|
358
|
+
webex.internal.newMetrics.callDiagnosticLatencies.getTotalMediaJMT = sinon
|
|
359
|
+
.stub()
|
|
360
|
+
.returns(44);
|
|
349
361
|
webex.internal.newMetrics.callDiagnosticLatencies.getTotalMediaJMTWithUserDelay = sinon
|
|
350
362
|
.stub()
|
|
351
363
|
.returns(43);
|
|
@@ -366,9 +378,9 @@ describe('plugin-metrics', () => {
|
|
|
366
378
|
assert.deepEqual(webex.request.getCalls()[0].args[0].body.metrics[0].eventPayload.event, {
|
|
367
379
|
name: 'client.media-engine.ready',
|
|
368
380
|
joinTimes: {
|
|
369
|
-
totalMediaJMT:
|
|
381
|
+
totalMediaJMT: 44,
|
|
370
382
|
interstitialToMediaOKJMT: 22,
|
|
371
|
-
callInitMediaEngineReady:
|
|
383
|
+
callInitMediaEngineReady: 22,
|
|
372
384
|
totalMediaJMTWithUserDelay: 43,
|
|
373
385
|
totalJMTWithUserDelay: 64,
|
|
374
386
|
},
|