@webex/calling 3.8.1-next.2 → 3.8.1-next.20

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.
Files changed (54) hide show
  1. package/dist/CallSettings/WxCallBackendConnector.js +2 -2
  2. package/dist/CallSettings/WxCallBackendConnector.js.map +1 -1
  3. package/dist/CallSettings/WxCallBackendConnector.test.js +94 -27
  4. package/dist/CallSettings/WxCallBackendConnector.test.js.map +1 -1
  5. package/dist/CallSettings/types.js.map +1 -1
  6. package/dist/CallingClient/CallingClient.js +56 -21
  7. package/dist/CallingClient/CallingClient.js.map +1 -1
  8. package/dist/CallingClient/CallingClient.test.js +168 -102
  9. package/dist/CallingClient/CallingClient.test.js.map +1 -1
  10. package/dist/CallingClient/constants.js +3 -4
  11. package/dist/CallingClient/constants.js.map +1 -1
  12. package/dist/CallingClient/line/line.test.js +4 -10
  13. package/dist/CallingClient/line/line.test.js.map +1 -1
  14. package/dist/CallingClient/registration/register.js +371 -285
  15. package/dist/CallingClient/registration/register.js.map +1 -1
  16. package/dist/CallingClient/registration/register.test.js +412 -300
  17. package/dist/CallingClient/registration/register.test.js.map +1 -1
  18. package/dist/CallingClient/registration/types.js.map +1 -1
  19. package/dist/CallingClient/registration/webWorker.js +115 -0
  20. package/dist/CallingClient/registration/webWorker.js.map +1 -0
  21. package/dist/CallingClient/registration/webWorker.test.js +256 -0
  22. package/dist/CallingClient/registration/webWorker.test.js.map +1 -0
  23. package/dist/CallingClient/registration/webWorkerStr.js +15 -0
  24. package/dist/CallingClient/registration/webWorkerStr.js.map +1 -0
  25. package/dist/common/Utils.js +13 -7
  26. package/dist/common/Utils.js.map +1 -1
  27. package/dist/common/Utils.test.js +265 -119
  28. package/dist/common/Utils.test.js.map +1 -1
  29. package/dist/common/types.js +8 -1
  30. package/dist/common/types.js.map +1 -1
  31. package/dist/module/CallSettings/WxCallBackendConnector.js +1 -1
  32. package/dist/module/CallingClient/CallingClient.js +23 -8
  33. package/dist/module/CallingClient/constants.js +1 -2
  34. package/dist/module/CallingClient/registration/register.js +93 -60
  35. package/dist/module/CallingClient/registration/webWorker.js +59 -0
  36. package/dist/module/CallingClient/registration/webWorkerStr.js +93 -0
  37. package/dist/module/common/Utils.js +8 -1
  38. package/dist/module/common/types.js +7 -0
  39. package/dist/types/CallSettings/types.d.ts +1 -1
  40. package/dist/types/CallSettings/types.d.ts.map +1 -1
  41. package/dist/types/CallingClient/CallingClient.d.ts.map +1 -1
  42. package/dist/types/CallingClient/constants.d.ts +1 -2
  43. package/dist/types/CallingClient/constants.d.ts.map +1 -1
  44. package/dist/types/CallingClient/registration/register.d.ts +2 -2
  45. package/dist/types/CallingClient/registration/register.d.ts.map +1 -1
  46. package/dist/types/CallingClient/registration/types.d.ts.map +1 -1
  47. package/dist/types/CallingClient/registration/webWorker.d.ts +2 -0
  48. package/dist/types/CallingClient/registration/webWorker.d.ts.map +1 -0
  49. package/dist/types/CallingClient/registration/webWorkerStr.d.ts +3 -0
  50. package/dist/types/CallingClient/registration/webWorkerStr.d.ts.map +1 -0
  51. package/dist/types/common/Utils.d.ts.map +1 -1
  52. package/dist/types/common/types.d.ts +12 -0
  53. package/dist/types/common/types.d.ts.map +1 -1
  54. package/package.json +4 -4
@@ -4,7 +4,7 @@ var _Object$defineProperty = require("@babel/runtime-corejs2/core-js/object/defi
4
4
  _Object$defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
- exports.ServiceIndicator = exports.SORT_BY = exports.SORT = exports.RegistrationStatus = exports.HTTP_METHODS = exports.DecodeType = exports.CallType = exports.CallDirection = exports.CALLING_BACKEND = exports.ALLOWED_SERVICES = void 0;
7
+ exports.WorkerMessageType = exports.ServiceIndicator = exports.SORT_BY = exports.SORT = exports.RegistrationStatus = exports.HTTP_METHODS = exports.DecodeType = exports.CallType = exports.CallDirection = exports.CALLING_BACKEND = exports.ALLOWED_SERVICES = void 0;
8
8
  var _constants = require("./constants");
9
9
  var ALLOWED_SERVICES = exports.ALLOWED_SERVICES = /*#__PURE__*/function (ALLOWED_SERVICES) {
10
10
  ALLOWED_SERVICES["MOBIUS"] = "mobius";
@@ -65,4 +65,11 @@ var DecodeType = exports.DecodeType = /*#__PURE__*/function (DecodeType) {
65
65
  DecodeType["ORGANIZATION"] = "ORGANIZATION";
66
66
  return DecodeType;
67
67
  }({});
68
+ var WorkerMessageType = exports.WorkerMessageType = /*#__PURE__*/function (WorkerMessageType) {
69
+ WorkerMessageType["START_KEEPALIVE"] = "START_KEEPALIVE";
70
+ WorkerMessageType["CLEAR_KEEPALIVE"] = "CLEAR_KEEPALIVE";
71
+ WorkerMessageType["KEEPALIVE_SUCCESS"] = "KEEPALIVE_SUCCESS";
72
+ WorkerMessageType["KEEPALIVE_FAILURE"] = "KEEPALIVE_FAILURE";
73
+ return WorkerMessageType;
74
+ }({});
68
75
  //# sourceMappingURL=types.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_constants","require","ALLOWED_SERVICES","exports","HTTP_METHODS","RegistrationStatus","CALLING_BACKEND","CallType","CallDirection","SORT","SORT_BY","ServiceIndicator","DecodeType"],"sources":["types.ts"],"sourcesContent":["import {SCIM_ENTERPRISE_USER, SCIM_WEBEXIDENTITY_USER} from './constants';\n\nexport type MobiusDeviceId = string;\nexport type MobiusDeviceUri = string;\nexport type SettingEnabled = boolean;\n\nexport enum ALLOWED_SERVICES {\n MOBIUS = 'mobius',\n JANUS = 'janus',\n}\nexport enum HTTP_METHODS {\n GET = 'GET',\n POST = 'POST',\n PATCH = 'PATCH',\n PUT = 'PUT',\n DELETE = 'DELETE',\n}\n\nexport enum RegistrationStatus {\n IDLE = 'IDLE',\n ACTIVE = 'active',\n INACTIVE = 'inactive',\n}\n\nexport enum CALLING_BACKEND {\n WXC = 'WEBEX_CALLING',\n BWRKS = 'BROADWORKS_CALLING',\n UCM = 'UCM_CALLING',\n INVALID = 'Calling backend is currently not supported',\n}\n\nexport type DeviceList = unknown;\nexport type CallId = string; // guid;\nexport type CorrelationId = string;\nexport enum CallType {\n URI = 'uri',\n TEL = 'tel',\n}\nexport type CallDetails = {\n type: CallType;\n address: string; // sip address\n};\n\nexport type CallDestination = CallDetails;\nexport enum CallDirection {\n INBOUND = 'inbound',\n OUTBOUND = 'outbound',\n}\nexport type AvatarId = string;\nexport type DisplayName = string;\nexport type DisplayInformation = {\n avatarSrc: AvatarId | undefined;\n name: DisplayName | undefined;\n num: string | undefined;\n id: string | undefined;\n};\n\nexport type WebexRequestPayload = {\n method?: HTTP_METHODS;\n uri?: string;\n addAuthHeader?: boolean;\n headers?: {\n [key: string]: string | null;\n };\n body?: object;\n statusCode?: number;\n json?: boolean;\n service?: ALLOWED_SERVICES;\n};\n\nexport type ErrorCode = string;\n\nexport type Digit = string | number;\n\nexport type ServerInfo = {\n region: string;\n uris: string[];\n};\n\nexport type MobiusServers = {\n primary: ServerInfo;\n backup: ServerInfo;\n};\n\nexport type IpInfo = {\n ipv4: string;\n ipv6: string;\n};\n\nexport type DeviceType = {\n deviceId: string;\n uri: string;\n status: string;\n lastSeen: string;\n addresses: string[];\n clientDeviceUri: string;\n};\n\nexport type RegionInfo = {\n countryCode: string;\n clientRegion: string;\n};\n\nexport interface IDeviceInfo {\n userId?: string;\n errorCode?: number;\n\n device?: DeviceType;\n devices?: DeviceType[];\n keepaliveInterval?: number;\n callKeepaliveInterval?: number;\n voicePortalNumber?: number;\n voicePortalExtension?: number;\n // cSpell:disable\n rehomingIntervalMin?: number;\n rehomingIntervalMax?: number;\n /* cSpell:enable */\n}\n\nexport interface IMetaContext {\n file?: string;\n method?: string;\n}\n\nexport enum SORT {\n ASC = 'ASC',\n DESC = 'DESC',\n DEFAULT = 'DESC',\n}\n\nexport enum SORT_BY {\n END_TIME = 'endTime',\n DEFAULT = 'endTime',\n START_TIME = 'startTime',\n}\n\nexport enum ServiceIndicator {\n CALLING = 'calling',\n CONTACT_CENTER = 'contactcenter',\n GUEST_CALLING = 'guestcalling',\n}\n\nexport type ServiceData = {\n indicator: ServiceIndicator;\n domain?: string;\n};\n\nexport type PhoneNumber = {\n type: string;\n value: string;\n primary?: boolean;\n};\n\nexport type PersonInfo = {\n id: string;\n emails: string[];\n phoneNumbers: PhoneNumber[];\n displayName: string;\n nickName: string;\n firstName: string;\n lastName: string;\n avatar: string;\n orgId: string;\n created: string;\n lastModified: string;\n lastActivity: string;\n status: string;\n type: string;\n};\n\nexport type PeopleListResponse = {\n items: PersonInfo[];\n notFoundIds: string[];\n};\n\nexport enum DecodeType {\n PEOPLE = 'PEOPLE',\n ORGANIZATION = 'ORGANIZATION',\n}\n\nexport type ContactDetail = {\n type?: string;\n value: string;\n};\n\nexport interface URIAddress {\n value: string;\n type: string;\n primary?: boolean;\n}\n\nexport type KmsKey = {\n uri: string;\n userId: string;\n createDate: string;\n expirationDate: string;\n bindDate?: string;\n resourceUri?: string;\n};\n\nexport type KmsResourceObject = {\n uri: string;\n keyUris: string[];\n authorizationUris: string[];\n};\n\nexport interface Name {\n familyName: string;\n givenName: string;\n}\n\nexport interface Address {\n city?: string;\n country?: string;\n state?: string;\n street?: string;\n zipCode?: string;\n}\n\ninterface WebexIdentityMeta {\n organizationId: string;\n}\ninterface WebexIdentityUser {\n sipAddresses?: URIAddress[];\n meta?: WebexIdentityMeta;\n}\n\ninterface Manager {\n value: string;\n displayName: string;\n $ref: string;\n}\n\ninterface EnterpriseUser {\n department?: string;\n manager?: Manager;\n}\n\ninterface Resource {\n schemas: string[];\n id: string;\n userName: string;\n active?: boolean;\n name?: Name;\n displayName?: string;\n emails?: URIAddress[];\n userType: string;\n phoneNumbers?: PhoneNumber[];\n photos?: ContactDetail[];\n addresses?: Address[];\n [SCIM_WEBEXIDENTITY_USER]?: WebexIdentityUser;\n [SCIM_ENTERPRISE_USER]?: EnterpriseUser;\n}\n\nexport interface SCIMListResponse {\n schemas: string[];\n totalResults: number;\n itemsPerPage: number;\n startIndex: number;\n Resources: Resource[];\n}\n\nexport type LogsMetaData = {\n callId?: string;\n feedbackId?: string;\n correlationId?: string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,gBAAA,0BAAhBA,gBAAgB;EAAhBA,gBAAgB;EAAhBA,gBAAgB;EAAhBA,gBAAgB;EAAA,OAAhBA,gBAAgB;AAAA;AAAA,IAuChBC,UAAU,GAAAT,OAAA,CAAAS,UAAA,0BAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAA,OAAVA,UAAU;AAAA"}
1
+ {"version":3,"names":["_constants","require","ALLOWED_SERVICES","exports","HTTP_METHODS","RegistrationStatus","CALLING_BACKEND","CallType","CallDirection","SORT","SORT_BY","ServiceIndicator","DecodeType","WorkerMessageType"],"sources":["types.ts"],"sourcesContent":["import {SCIM_ENTERPRISE_USER, SCIM_WEBEXIDENTITY_USER} from './constants';\n\nexport type MobiusDeviceId = string;\nexport type MobiusDeviceUri = string;\nexport type SettingEnabled = boolean;\n\nexport enum ALLOWED_SERVICES {\n MOBIUS = 'mobius',\n JANUS = 'janus',\n}\nexport enum HTTP_METHODS {\n GET = 'GET',\n POST = 'POST',\n PATCH = 'PATCH',\n PUT = 'PUT',\n DELETE = 'DELETE',\n}\n\nexport enum RegistrationStatus {\n IDLE = 'IDLE',\n ACTIVE = 'active',\n INACTIVE = 'inactive',\n}\n\nexport enum CALLING_BACKEND {\n WXC = 'WEBEX_CALLING',\n BWRKS = 'BROADWORKS_CALLING',\n UCM = 'UCM_CALLING',\n INVALID = 'Calling backend is currently not supported',\n}\n\nexport type DeviceList = unknown;\nexport type CallId = string; // guid;\nexport type CorrelationId = string;\nexport enum CallType {\n URI = 'uri',\n TEL = 'tel',\n}\nexport type CallDetails = {\n type: CallType;\n address: string; // sip address\n};\n\nexport type CallDestination = CallDetails;\nexport enum CallDirection {\n INBOUND = 'inbound',\n OUTBOUND = 'outbound',\n}\nexport type AvatarId = string;\nexport type DisplayName = string;\nexport type DisplayInformation = {\n avatarSrc: AvatarId | undefined;\n name: DisplayName | undefined;\n num: string | undefined;\n id: string | undefined;\n};\n\nexport type WebexRequestPayload = {\n method?: HTTP_METHODS;\n uri?: string;\n addAuthHeader?: boolean;\n headers?: {\n [key: string]: string | null;\n };\n body?: object;\n statusCode?: number;\n json?: boolean;\n service?: ALLOWED_SERVICES;\n};\n\nexport type ErrorCode = string;\n\nexport type Digit = string | number;\n\nexport type ServerInfo = {\n region: string;\n uris: string[];\n};\n\nexport type MobiusServers = {\n primary: ServerInfo;\n backup: ServerInfo;\n};\n\nexport type IpInfo = {\n ipv4: string;\n ipv6: string;\n};\n\nexport type DeviceType = {\n deviceId: string;\n uri: string;\n status: string;\n lastSeen: string;\n addresses: string[];\n clientDeviceUri: string;\n};\n\nexport type RegionInfo = {\n countryCode: string;\n clientRegion: string;\n};\n\nexport interface IDeviceInfo {\n userId?: string;\n errorCode?: number;\n\n device?: DeviceType;\n devices?: DeviceType[];\n keepaliveInterval?: number;\n callKeepaliveInterval?: number;\n voicePortalNumber?: number;\n voicePortalExtension?: number;\n // cSpell:disable\n rehomingIntervalMin?: number;\n rehomingIntervalMax?: number;\n /* cSpell:enable */\n}\n\nexport interface IMetaContext {\n file?: string;\n method?: string;\n}\n\nexport enum SORT {\n ASC = 'ASC',\n DESC = 'DESC',\n DEFAULT = 'DESC',\n}\n\nexport enum SORT_BY {\n END_TIME = 'endTime',\n DEFAULT = 'endTime',\n START_TIME = 'startTime',\n}\n\nexport enum ServiceIndicator {\n CALLING = 'calling',\n CONTACT_CENTER = 'contactcenter',\n GUEST_CALLING = 'guestcalling',\n}\n\nexport type ServiceData = {\n indicator: ServiceIndicator;\n domain?: string;\n};\n\nexport type PhoneNumber = {\n type: string;\n value: string;\n primary?: boolean;\n};\n\nexport type PersonInfo = {\n id: string;\n emails: string[];\n phoneNumbers: PhoneNumber[];\n displayName: string;\n nickName: string;\n firstName: string;\n lastName: string;\n avatar: string;\n orgId: string;\n created: string;\n lastModified: string;\n lastActivity: string;\n status: string;\n type: string;\n};\n\nexport type PeopleListResponse = {\n items: PersonInfo[];\n notFoundIds: string[];\n};\n\nexport enum DecodeType {\n PEOPLE = 'PEOPLE',\n ORGANIZATION = 'ORGANIZATION',\n}\n\nexport type ContactDetail = {\n type?: string;\n value: string;\n};\n\nexport interface URIAddress {\n value: string;\n type: string;\n primary?: boolean;\n}\n\nexport type KmsKey = {\n uri: string;\n userId: string;\n createDate: string;\n expirationDate: string;\n bindDate?: string;\n resourceUri?: string;\n};\n\nexport type KmsResourceObject = {\n uri: string;\n keyUris: string[];\n authorizationUris: string[];\n};\n\nexport interface Name {\n familyName: string;\n givenName: string;\n}\n\nexport interface Address {\n city?: string;\n country?: string;\n state?: string;\n street?: string;\n zipCode?: string;\n}\n\ninterface WebexIdentityMeta {\n organizationId: string;\n}\ninterface WebexIdentityUser {\n sipAddresses?: URIAddress[];\n meta?: WebexIdentityMeta;\n}\n\ninterface Manager {\n value: string;\n displayName: string;\n $ref: string;\n}\n\ninterface EnterpriseUser {\n department?: string;\n manager?: Manager;\n}\n\ninterface Resource {\n schemas: string[];\n id: string;\n userName: string;\n active?: boolean;\n name?: Name;\n displayName?: string;\n emails?: URIAddress[];\n userType: string;\n phoneNumbers?: PhoneNumber[];\n photos?: ContactDetail[];\n addresses?: Address[];\n [SCIM_WEBEXIDENTITY_USER]?: WebexIdentityUser;\n [SCIM_ENTERPRISE_USER]?: EnterpriseUser;\n}\n\nexport interface SCIMListResponse {\n schemas: string[];\n totalResults: number;\n itemsPerPage: number;\n startIndex: number;\n Resources: Resource[];\n}\n\nexport enum WorkerMessageType {\n START_KEEPALIVE = 'START_KEEPALIVE',\n CLEAR_KEEPALIVE = 'CLEAR_KEEPALIVE',\n KEEPALIVE_SUCCESS = 'KEEPALIVE_SUCCESS',\n KEEPALIVE_FAILURE = 'KEEPALIVE_FAILURE',\n}\n\nexport type KeepaliveStatusMessage = {\n type: WorkerMessageType.KEEPALIVE_SUCCESS | WorkerMessageType.KEEPALIVE_FAILURE;\n err?: unknown;\n keepAliveRetryCount?: number;\n statusCode?: number;\n};\n\nexport type LogsMetaData = {\n callId?: string;\n feedbackId?: string;\n correlationId?: string;\n};\n\nex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BAAhBA,gBAAgB;EAAhBA,gBAAgB;EAAhBA,gBAAgB;EAAhBA,gBAAgB;EAAA,OAAhBA,gBAAgB;AAAA;AAAA,IAuChBC,UAAU,GAAAT,OAAA,CAAAS,UAAA,0BAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAA,OAAVA,UAAU;AAAA;AAAA,IAuFVC,iBAAiB,GAAAV,OAAA,CAAAU,iBAAA,0BAAjBA,iBAAiB;EAAjBA,iBAAiB;EAAjBA,iBAAiB;EAAjBA,iBAAiB;EAAjBA,iBAAiB;EAAA,OAAjBA,iBAAiB;AAAA"}
@@ -289,7 +289,7 @@ export class WxCallBackendConnector {
289
289
  const vmResponse = await this.getVoicemailSetting();
290
290
  if (vmResponse.statusCode === 200) {
291
291
  const vm = vmResponse.data.callSetting;
292
- if (vm.enabled && vm.sendAllCalls.enabled) {
292
+ if (vm.enabled && vm.sendAllCalls?.enabled) {
293
293
  const response = {
294
294
  ...cfResponse,
295
295
  data: {
@@ -69,12 +69,18 @@ export class CallingClient extends Eventing {
69
69
  method: this.constructor.name,
70
70
  });
71
71
  }
72
- this.mobiusClusters =
73
- (mobiusServiceHost && this.webex.internal.services._hostCatalog[mobiusServiceHost]) ||
74
- this.webex.internal.services._hostCatalog[MOBIUS_US_PROD] ||
75
- this.webex.internal.services._hostCatalog[MOBIUS_EU_PROD] ||
76
- this.webex.internal.services._hostCatalog[MOBIUS_US_INT] ||
77
- this.webex.internal.services._hostCatalog[MOBIUS_EU_INT];
72
+ if (this.webex.internal.services._hostCatalog) {
73
+ this.mobiusClusters =
74
+ (mobiusServiceHost && this.webex.internal.services._hostCatalog[mobiusServiceHost]) ||
75
+ this.webex.internal.services._hostCatalog[MOBIUS_US_PROD] ||
76
+ this.webex.internal.services._hostCatalog[MOBIUS_EU_PROD] ||
77
+ this.webex.internal.services._hostCatalog[MOBIUS_US_INT] ||
78
+ this.webex.internal.services._hostCatalog[MOBIUS_EU_INT];
79
+ }
80
+ else {
81
+ const mobiusObject = this.webex.internal.services._services.find((item) => item.serviceName === 'mobius');
82
+ this.mobiusClusters = [mobiusObject.serviceUrls[0].baseUrl];
83
+ }
78
84
  this.mobiusHost = '';
79
85
  this.registerSessionsListener();
80
86
  this.registerCallsClearedListener();
@@ -113,13 +119,19 @@ export class CallingClient extends Eventing {
113
119
  }, NETWORK_FLAP_TIMEOUT);
114
120
  }
115
121
  async getClientRegionInfo() {
122
+ let abort;
116
123
  log.info(METHOD_START_MESSAGE, {
117
124
  file: CALLING_CLIENT_FILE,
118
125
  method: METHODS.GET_CLIENT_REGION_INFO,
119
126
  });
120
127
  const regionInfo = {};
121
128
  for (const mobius of this.mobiusClusters) {
122
- this.mobiusHost = `https://${mobius.host}${API_V1}`;
129
+ if (mobius.host) {
130
+ this.mobiusHost = `https://${mobius.host}${API_V1}`;
131
+ }
132
+ else {
133
+ this.mobiusHost = mobius;
134
+ }
123
135
  try {
124
136
  const temp = await this.webex.request({
125
137
  uri: `${this.mobiusHost}${URL_ENDPOINT}${IP_ENDPOINT}`,
@@ -152,12 +164,15 @@ export class CallingClient extends Eventing {
152
164
  method: METHODS.GET_CLIENT_REGION_INFO,
153
165
  file: CALLING_CLIENT_FILE,
154
166
  });
155
- handleCallingClientErrors(err, (clientError) => {
167
+ abort = await handleCallingClientErrors(err, (clientError) => {
156
168
  this.metricManager.submitRegistrationMetric(METRIC_EVENT.REGISTRATION_ERROR, REG_ACTION.REGISTER, METRIC_TYPE.BEHAVIORAL, GET_MOBIUS_SERVERS_UTIL, 'UNKNOWN', err.headers?.trackingId ?? '', undefined, clientError);
157
169
  this.emit(CALLING_CLIENT_EVENT_KEYS.ERROR, clientError);
158
170
  }, { method: GET_MOBIUS_SERVERS_UTIL, file: CALLING_CLIENT_FILE });
159
171
  regionInfo.clientRegion = '';
160
172
  regionInfo.countryCode = '';
173
+ if (abort) {
174
+ return regionInfo;
175
+ }
161
176
  }
162
177
  }
163
178
  return regionInfo;
@@ -105,8 +105,7 @@ export const BASE_REG_RETRY_TIMER_VAL_IN_SEC = 30;
105
105
  export const SEC_TO_MSEC_MFACTOR = 1000;
106
106
  export const MINUTES_TO_SEC_MFACTOR = 60;
107
107
  export const REG_RANDOM_T_FACTOR_UPPER_LIMIT = 10000;
108
- export const REG_TRY_BACKUP_TIMER_VAL_IN_SEC = 1200;
109
- export const REG_TRY_BACKUP_TIMER_VAL_FOR_CC_IN_SEC = 114;
108
+ export const REG_TRY_BACKUP_TIMER_VAL_IN_SEC = 114;
110
109
  export const REG_FAILBACK_429_MAX_RETRIES = 5;
111
110
  export const RETRY_TIMER_UPPER_LIMIT = 60;
112
111
  export const REGISTRATION_UTIL = 'triggerRegistration';
@@ -1,13 +1,14 @@
1
1
  import { v4 as uuid } from 'uuid';
2
2
  import { METHOD_START_MESSAGE } from '../../common/constants';
3
3
  import { emitFinalFailure, handleRegistrationErrors, uploadLogs } from '../../common';
4
+ import webWorkerStr from './webWorkerStr';
4
5
  import { METRIC_EVENT, METRIC_TYPE, REG_ACTION, } from '../../Metrics/types';
5
6
  import { getMetricManager } from '../../Metrics';
6
7
  import { getCallManager } from '../calling';
7
8
  import log from '../../Logger';
8
9
  import SDKConnector from '../../SDKConnector';
9
- import { ALLOWED_SERVICES, HTTP_METHODS, RegistrationStatus, ServiceIndicator, } from '../../common/types';
10
- import { CALLING_USER_AGENT, CISCO_DEVICE_URL, DEVICES_ENDPOINT_RESOURCE, SPARK_USER_AGENT, WEBEX_WEB_CLIENT, BASE_REG_RETRY_TIMER_VAL_IN_SEC, BASE_REG_TIMER_MFACTOR, SEC_TO_MSEC_MFACTOR, REG_RANDOM_T_FACTOR_UPPER_LIMIT, REG_TRY_BACKUP_TIMER_VAL_IN_SEC, MINUTES_TO_SEC_MFACTOR, REG_429_RETRY_UTIL, REG_FAILBACK_429_MAX_RETRIES, FAILBACK_UTIL, REGISTRATION_FILE, DEFAULT_REHOMING_INTERVAL_MIN, DEFAULT_REHOMING_INTERVAL_MAX, DEFAULT_KEEPALIVE_INTERVAL, REG_TRY_BACKUP_TIMER_VAL_FOR_CC_IN_SEC, FAILOVER_UTIL, REGISTER_UTIL, RETRY_TIMER_UPPER_LIMIT, KEEPALIVE_UTIL, REGISTRATION_UTIL, METHODS, } from '../constants';
10
+ import { ALLOWED_SERVICES, HTTP_METHODS, RegistrationStatus, ServiceIndicator, WorkerMessageType, } from '../../common/types';
11
+ import { CALLING_USER_AGENT, CISCO_DEVICE_URL, DEVICES_ENDPOINT_RESOURCE, SPARK_USER_AGENT, WEBEX_WEB_CLIENT, BASE_REG_RETRY_TIMER_VAL_IN_SEC, BASE_REG_TIMER_MFACTOR, SEC_TO_MSEC_MFACTOR, REG_RANDOM_T_FACTOR_UPPER_LIMIT, REG_TRY_BACKUP_TIMER_VAL_IN_SEC, MINUTES_TO_SEC_MFACTOR, REG_429_RETRY_UTIL, REG_FAILBACK_429_MAX_RETRIES, FAILBACK_UTIL, REGISTRATION_FILE, DEFAULT_REHOMING_INTERVAL_MIN, DEFAULT_REHOMING_INTERVAL_MAX, DEFAULT_KEEPALIVE_INTERVAL, FAILOVER_UTIL, REGISTER_UTIL, RETRY_TIMER_UPPER_LIMIT, KEEPALIVE_UTIL, REGISTRATION_UTIL, METHODS, URL_ENDPOINT, } from '../constants';
11
12
  import { LINE_EVENTS } from '../line/types';
12
13
  export class Registration {
13
14
  sdkConnector;
@@ -18,7 +19,6 @@ export class Registration {
18
19
  registrationStatus;
19
20
  failbackTimer;
20
21
  activeMobiusUrl;
21
- keepaliveTimer;
22
22
  rehomingIntervalMin;
23
23
  rehomingIntervalMax;
24
24
  mutex;
@@ -35,6 +35,7 @@ export class Registration {
35
35
  failoverImmediately = false;
36
36
  retryAfter;
37
37
  scheduled429Retry = false;
38
+ webWorker;
38
39
  constructor(webex, serviceData, mutex, lineEmitter, logLevel, jwe) {
39
40
  this.jwe = jwe;
40
41
  this.sdkConnector = SDKConnector;
@@ -73,17 +74,6 @@ export class Registration {
73
74
  this.primaryMobiusUris = primaryMobiusUris;
74
75
  this.backupMobiusUris = backupMobiusUris;
75
76
  }
76
- async postKeepAlive(url) {
77
- return this.webex.request({
78
- uri: `${url}/status`,
79
- method: HTTP_METHODS.POST,
80
- headers: {
81
- [CISCO_DEVICE_URL]: this.webex.internal.device.url,
82
- [SPARK_USER_AGENT]: CALLING_USER_AGENT,
83
- },
84
- service: ALLOWED_SERVICES.MOBIUS,
85
- });
86
- }
87
77
  async deleteRegistration(url, deviceId, deviceUrl) {
88
78
  let response;
89
79
  try {
@@ -167,9 +157,7 @@ export class Registration {
167
157
  method: FAILOVER_UTIL,
168
158
  };
169
159
  let interval = this.getRegRetryInterval(attempt);
170
- const TIMER_THRESHOLD = this.isCCFlow
171
- ? REG_TRY_BACKUP_TIMER_VAL_FOR_CC_IN_SEC
172
- : REG_TRY_BACKUP_TIMER_VAL_IN_SEC;
160
+ const TIMER_THRESHOLD = REG_TRY_BACKUP_TIMER_VAL_IN_SEC;
173
161
  if (timeElapsed + interval > TIMER_THRESHOLD) {
174
162
  const excessVal = timeElapsed + interval - TIMER_THRESHOLD;
175
163
  interval -= excessVal;
@@ -230,6 +218,40 @@ export class Registration {
230
218
  this.failbackTimer = undefined;
231
219
  }
232
220
  }
221
+ async isPrimaryActive() {
222
+ let status;
223
+ for (const mobiusUrl of this.primaryMobiusUris) {
224
+ try {
225
+ const baseUri = mobiusUrl.replace(URL_ENDPOINT, '/');
226
+ const response = await this.webex.request({
227
+ uri: `${baseUri}ping`,
228
+ method: HTTP_METHODS.GET,
229
+ headers: {
230
+ [CISCO_DEVICE_URL]: this.webex.internal.device.url,
231
+ [SPARK_USER_AGENT]: CALLING_USER_AGENT,
232
+ },
233
+ service: ALLOWED_SERVICES.MOBIUS,
234
+ });
235
+ const { statusCode } = response;
236
+ if (statusCode === 200) {
237
+ log.info(`Ping successful for primary Mobius: ${mobiusUrl}`, {
238
+ file: REGISTRATION_FILE,
239
+ method: FAILBACK_UTIL,
240
+ });
241
+ status = 'up';
242
+ break;
243
+ }
244
+ }
245
+ catch (error) {
246
+ log.warn(`Ping failed for primary Mobius: ${mobiusUrl} with error: ${error}`, {
247
+ file: REGISTRATION_FILE,
248
+ method: FAILBACK_UTIL,
249
+ });
250
+ status = 'down';
251
+ }
252
+ }
253
+ return status === 'up';
254
+ }
233
255
  isFailbackRequired() {
234
256
  return this.isDeviceRegistered() && this.primaryMobiusUris.indexOf(this.activeMobiusUrl) === -1;
235
257
  }
@@ -260,7 +282,8 @@ export class Registration {
260
282
  async executeFailback() {
261
283
  await this.mutex.runExclusive(async () => {
262
284
  if (this.isFailbackRequired()) {
263
- if (Object.keys(this.callManager.getActiveCalls()).length === 0) {
285
+ const primaryServerStatus = await this.isPrimaryActive();
286
+ if (Object.keys(this.callManager.getActiveCalls()).length === 0 && primaryServerStatus) {
264
287
  log.info(`Attempting failback to primary.`, {
265
288
  file: REGISTRATION_FILE,
266
289
  method: this.executeFailback.name,
@@ -284,7 +307,7 @@ export class Registration {
284
307
  }
285
308
  }
286
309
  else {
287
- log.info('Active calls present, deferring failback to next cycle.', {
310
+ log.info('Active calls present or primary Mobius is down, deferring failback to next cycle.', {
288
311
  file: REGISTRATION_FILE,
289
312
  method: this.executeFailback.name,
290
313
  });
@@ -449,57 +472,67 @@ export class Registration {
449
472
  }
450
473
  return abort;
451
474
  }
452
- startKeepaliveTimer(url, interval, serverType) {
453
- let keepAliveRetryCount = 0;
475
+ async startKeepaliveTimer(url, interval, serverType) {
454
476
  this.clearKeepaliveTimer();
455
477
  const RETRY_COUNT_THRESHOLD = this.isCCFlow ? 4 : 5;
456
- this.keepaliveTimer = setInterval(async () => {
457
- const logContext = {
458
- file: REGISTRATION_FILE,
459
- method: KEEPALIVE_UTIL,
460
- };
461
- await this.mutex.runExclusive(async () => {
462
- if (this.isDeviceRegistered() && keepAliveRetryCount < RETRY_COUNT_THRESHOLD) {
463
- try {
464
- const res = await this.postKeepAlive(url);
465
- log.log(`Sent Keepalive, status: ${res.statusCode}`, logContext);
466
- if (keepAliveRetryCount > 0) {
478
+ await this.mutex.runExclusive(async () => {
479
+ if (this.isDeviceRegistered()) {
480
+ const accessToken = await this.webex.credentials.getUserToken();
481
+ if (!this.webWorker) {
482
+ const blob = new Blob([webWorkerStr], { type: 'application/javascript' });
483
+ const blobUrl = URL.createObjectURL(blob);
484
+ this.webWorker = new Worker(blobUrl);
485
+ URL.revokeObjectURL(blobUrl);
486
+ this.webWorker.postMessage({
487
+ type: WorkerMessageType.START_KEEPALIVE,
488
+ accessToken: String(accessToken),
489
+ deviceUrl: String(this.webex.internal.device.url),
490
+ interval,
491
+ retryCountThreshold: RETRY_COUNT_THRESHOLD,
492
+ url,
493
+ });
494
+ this.webWorker.onmessage = async (event) => {
495
+ const logContext = {
496
+ file: REGISTRATION_FILE,
497
+ method: this.startKeepaliveTimer.name,
498
+ };
499
+ if (event.data.type === WorkerMessageType.KEEPALIVE_SUCCESS) {
500
+ log.info(`Sent Keepalive, status: ${event.data.statusCode}`, logContext);
467
501
  this.lineEmitter(LINE_EVENTS.RECONNECTED);
468
502
  }
469
- keepAliveRetryCount = 0;
470
- }
471
- catch (err) {
472
- keepAliveRetryCount += 1;
473
- const error = err;
474
- log.warn(`Keep-alive missed ${keepAliveRetryCount} times. Status -> ${error.statusCode} `, logContext);
475
- const abort = await handleRegistrationErrors(error, (clientError, finalError) => {
476
- if (finalError) {
477
- this.lineEmitter(LINE_EVENTS.ERROR, undefined, clientError);
503
+ if (event.data.type === WorkerMessageType.KEEPALIVE_FAILURE) {
504
+ const error = event.data.err;
505
+ log.warn(`Keep-alive missed ${event.data.keepAliveRetryCount} times. Status -> ${error.statusCode} `, logContext);
506
+ const abort = await handleRegistrationErrors(error, (clientError, finalError) => {
507
+ if (finalError) {
508
+ this.lineEmitter(LINE_EVENTS.ERROR, undefined, clientError);
509
+ }
510
+ this.metricManager.submitRegistrationMetric(METRIC_EVENT.REGISTRATION, REG_ACTION.KEEPALIVE_FAILURE, METRIC_TYPE.BEHAVIORAL, KEEPALIVE_UTIL, serverType, error.headers?.trackingid ?? '', event.data.keepAliveRetryCount, clientError);
511
+ }, { method: KEEPALIVE_UTIL, file: REGISTRATION_FILE });
512
+ if (abort || event.data.keepAliveRetryCount >= RETRY_COUNT_THRESHOLD) {
513
+ this.failoverImmediately = this.isCCFlow;
514
+ this.setStatus(RegistrationStatus.INACTIVE);
515
+ this.clearKeepaliveTimer();
516
+ this.clearFailbackTimer();
517
+ this.lineEmitter(LINE_EVENTS.UNREGISTERED);
518
+ if (!abort) {
519
+ await this.reconnectOnFailure(KEEPALIVE_UTIL);
520
+ }
478
521
  }
479
- this.metricManager.submitRegistrationMetric(METRIC_EVENT.REGISTRATION, REG_ACTION.KEEPALIVE_FAILURE, METRIC_TYPE.BEHAVIORAL, KEEPALIVE_UTIL, serverType, error.headers?.trackingid ?? '', keepAliveRetryCount, clientError);
480
- }, { method: KEEPALIVE_UTIL, file: REGISTRATION_FILE });
481
- if (abort || keepAliveRetryCount >= RETRY_COUNT_THRESHOLD) {
482
- this.failoverImmediately = this.isCCFlow;
483
- this.setStatus(RegistrationStatus.INACTIVE);
484
- this.clearKeepaliveTimer();
485
- this.clearFailbackTimer();
486
- this.lineEmitter(LINE_EVENTS.UNREGISTERED);
487
- if (!abort) {
488
- await this.reconnectOnFailure(KEEPALIVE_UTIL);
522
+ else {
523
+ this.lineEmitter(LINE_EVENTS.RECONNECTING);
489
524
  }
490
525
  }
491
- else {
492
- this.lineEmitter(LINE_EVENTS.RECONNECTING);
493
- }
494
- }
526
+ };
495
527
  }
496
- });
497
- }, interval * 1000);
528
+ }
529
+ });
498
530
  }
499
531
  clearKeepaliveTimer() {
500
- if (this.keepaliveTimer) {
501
- clearInterval(this.keepaliveTimer);
502
- this.keepaliveTimer = undefined;
532
+ if (this.webWorker) {
533
+ this.webWorker.postMessage({ type: WorkerMessageType.CLEAR_KEEPALIVE });
534
+ this.webWorker.terminate();
535
+ this.webWorker = undefined;
503
536
  }
504
537
  }
505
538
  isReconnectPending() {
@@ -0,0 +1,59 @@
1
+ import { v4 as uuid } from 'uuid';
2
+ import { HTTP_METHODS, WorkerMessageType } from '../../common/types';
3
+ let keepaliveTimer;
4
+ export const messageHandler = (event) => {
5
+ const { type } = event.data;
6
+ const postKeepAlive = async (accessToken, deviceUrl, url) => {
7
+ const response = await fetch(`${url}/status`, {
8
+ method: HTTP_METHODS.POST,
9
+ headers: {
10
+ 'cisco-device-url': deviceUrl,
11
+ 'spark-user-agent': 'webex-calling/beta',
12
+ Authorization: `${accessToken}`,
13
+ trackingId: `web_worker_${uuid()}`,
14
+ },
15
+ });
16
+ if (!response.ok) {
17
+ throw new Error(`Keepalive failed with status: ${response.status}`);
18
+ }
19
+ return response;
20
+ };
21
+ if (type === WorkerMessageType.START_KEEPALIVE) {
22
+ let keepAliveRetryCount = 0;
23
+ const { accessToken, deviceUrl, interval, retryCountThreshold, url } = event.data;
24
+ if (keepaliveTimer) {
25
+ clearInterval(keepaliveTimer);
26
+ keepaliveTimer = undefined;
27
+ }
28
+ keepaliveTimer = setInterval(async () => {
29
+ if (keepAliveRetryCount < retryCountThreshold) {
30
+ try {
31
+ const res = await postKeepAlive(accessToken, deviceUrl, url);
32
+ const statusCode = res.status;
33
+ if (keepAliveRetryCount > 0) {
34
+ postMessage({
35
+ type: WorkerMessageType.KEEPALIVE_SUCCESS,
36
+ statusCode,
37
+ });
38
+ }
39
+ keepAliveRetryCount = 0;
40
+ }
41
+ catch (err) {
42
+ keepAliveRetryCount += 1;
43
+ postMessage({
44
+ type: WorkerMessageType.KEEPALIVE_FAILURE,
45
+ err,
46
+ keepAliveRetryCount,
47
+ });
48
+ }
49
+ }
50
+ }, interval * 1000);
51
+ }
52
+ if (type === WorkerMessageType.CLEAR_KEEPALIVE) {
53
+ if (keepaliveTimer) {
54
+ clearInterval(keepaliveTimer);
55
+ keepaliveTimer = undefined;
56
+ }
57
+ }
58
+ };
59
+ self.addEventListener('message', messageHandler);
@@ -0,0 +1,93 @@
1
+ const webWorkerStr = `/* eslint-env worker */
2
+
3
+ const uuid = () => {
4
+ return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
5
+ const r = (Math.random() * 16) | 0;
6
+ const v = c === 'x' ? r : (r & 0x3) | 0x8;
7
+ return v.toString(16);
8
+ });
9
+ };
10
+
11
+ // Enum values from the original imports
12
+ const HTTP_METHODS = {
13
+ GET: 'GET',
14
+ POST: 'POST',
15
+ PUT: 'PUT',
16
+ DELETE: 'DELETE',
17
+ PATCH: 'PATCH',
18
+ };
19
+
20
+ const WorkerMessageType = {
21
+ START_KEEPALIVE: 'START_KEEPALIVE',
22
+ CLEAR_KEEPALIVE: 'CLEAR_KEEPALIVE',
23
+ KEEPALIVE_SUCCESS: 'KEEPALIVE_SUCCESS',
24
+ KEEPALIVE_FAILURE: 'KEEPALIVE_FAILURE',
25
+ };
26
+
27
+ let keepaliveTimer;
28
+
29
+ const messageHandler = (event) => {
30
+ const {type} = event.data;
31
+
32
+ const postKeepAlive = async (accessToken, deviceUrl, url) => {
33
+ const response = await fetch(\`\${url}/status\`, {
34
+ method: HTTP_METHODS.POST,
35
+ headers: {
36
+ 'cisco-device-url': deviceUrl,
37
+ 'spark-user-agent': 'webex-calling/beta',
38
+ Authorization: \`\${accessToken}\`,
39
+ trackingId: \`web_worker_\${uuid()}\`,
40
+ },
41
+ });
42
+
43
+ if (!response.ok) {
44
+ throw new Error(\`Keepalive failed with status: \${response.status}\`);
45
+ }
46
+
47
+ return response;
48
+ };
49
+
50
+ if (type === WorkerMessageType.START_KEEPALIVE) {
51
+ let keepAliveRetryCount = 0;
52
+ const {accessToken, deviceUrl, interval, retryCountThreshold, url} = event.data;
53
+
54
+ if (keepaliveTimer) {
55
+ clearInterval(keepaliveTimer);
56
+ keepaliveTimer = undefined;
57
+ }
58
+
59
+ keepaliveTimer = setInterval(async () => {
60
+ if (keepAliveRetryCount < retryCountThreshold) {
61
+ try {
62
+ const res = await postKeepAlive(accessToken, deviceUrl, url);
63
+ const statusCode = res.status;
64
+ if (keepAliveRetryCount > 0) {
65
+ self.postMessage({
66
+ type: WorkerMessageType.KEEPALIVE_SUCCESS,
67
+ statusCode,
68
+ });
69
+ }
70
+ keepAliveRetryCount = 0;
71
+ } catch (err) {
72
+ keepAliveRetryCount += 1;
73
+ self.postMessage({
74
+ type: WorkerMessageType.KEEPALIVE_FAILURE,
75
+ err,
76
+ keepAliveRetryCount,
77
+ });
78
+ }
79
+ }
80
+ }, interval * 1000);
81
+ }
82
+
83
+ if (type === WorkerMessageType.CLEAR_KEEPALIVE) {
84
+ if (keepaliveTimer) {
85
+ clearInterval(keepaliveTimer);
86
+ keepaliveTimer = undefined;
87
+ }
88
+ }
89
+ };
90
+
91
+ self.addEventListener('message', messageHandler);
92
+ `;
93
+ export default webWorkerStr;
@@ -183,9 +183,16 @@ export async function handleRegistrationErrors(err, emitterCb, loggerContext, re
183
183
  export async function handleCallingClientErrors(err, emitterCb, loggerContext) {
184
184
  const clientError = createClientError('', {}, ERROR_TYPE.DEFAULT, RegistrationStatus.INACTIVE);
185
185
  const errorCode = Number(err.statusCode);
186
- const finalError = false;
186
+ let finalError = false;
187
187
  log.warn(`Status code: -> ${errorCode}`, loggerContext);
188
188
  switch (errorCode) {
189
+ case ERROR_CODE.UNAUTHORIZED: {
190
+ finalError = true;
191
+ log.warn(`401 Unauthorized`, loggerContext);
192
+ updateErrorContext(loggerContext, ERROR_TYPE.TOKEN_ERROR, 'User is unauthorized due to an expired token.', clientError);
193
+ emitterCb(clientError, finalError);
194
+ break;
195
+ }
189
196
  case ERROR_CODE.INTERNAL_SERVER_ERROR: {
190
197
  log.warn(`500 Internal Server Error`, loggerContext);
191
198
  updateErrorContext(loggerContext, ERROR_TYPE.SERVER_ERROR, 'An unknown error occurred while placing the request. Wait a moment and try again.', clientError);
@@ -58,3 +58,10 @@ export var DecodeType;
58
58
  DecodeType["PEOPLE"] = "PEOPLE";
59
59
  DecodeType["ORGANIZATION"] = "ORGANIZATION";
60
60
  })(DecodeType || (DecodeType = {}));
61
+ export var WorkerMessageType;
62
+ (function (WorkerMessageType) {
63
+ WorkerMessageType["START_KEEPALIVE"] = "START_KEEPALIVE";
64
+ WorkerMessageType["CLEAR_KEEPALIVE"] = "CLEAR_KEEPALIVE";
65
+ WorkerMessageType["KEEPALIVE_SUCCESS"] = "KEEPALIVE_SUCCESS";
66
+ WorkerMessageType["KEEPALIVE_FAILURE"] = "KEEPALIVE_FAILURE";
67
+ })(WorkerMessageType || (WorkerMessageType = {}));
@@ -36,7 +36,7 @@ export type CallForwardSetting = {
36
36
  };
37
37
  export type VoicemailSetting = {
38
38
  enabled: boolean;
39
- sendAllCalls: {
39
+ sendAllCalls?: {
40
40
  enabled: boolean;
41
41
  };
42
42
  sendBusyCalls: {
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/CallSettings/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,MAAM,EAAC,MAAM,iBAAiB,CAAC;AAEvC,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,MAAM,aAAa,GAAG;IAC1B,OAAO,EAAE,OAAO,CAAC;IACjB,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B,CAAC;AAKF,MAAM,MAAM,wBAAwB,GAAG;IAIrC,OAAO,EAAE,OAAO,CAAC;IAIjB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAK9B,2BAA2B,CAAC,EAAE,OAAO,CAAC;IAKtC,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAKF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,cAAc,EAAE;QAId,MAAM,EAAE,wBAAwB,CAAC;QAIjC,IAAI,EAAE;YAIJ,OAAO,EAAE,OAAO,CAAC;YAKjB,2BAA2B,CAAC,EAAE,OAAO,CAAC;YAKtC,WAAW,CAAC,EAAE,MAAM,CAAC;SACtB,CAAC;QAIF,QAAQ,EAAE;YAIR,OAAO,EAAE,OAAO,CAAC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;IAEpB,WAAW,EAAE,OAAO,KAAK,CAAC;IAEjC,OAAO,CAAC,QAAQ,CAA6B;gBAKjC,KAAK,EAAE,QAAQ,EAAE,MAAM,CAAC,EAAE,mBAAmB;IAwF5C,IAAI;YAWH,mBAAmB;YAwCnB,mBAAmB;YA0FnB,gBAAgB;IAuH9B,OAAO,CAAC,4BAA4B;IAgBpC,OAAO,CAAC,mBAAmB,CAoBzB;IAMK,eAAe,IAAI,MAAM;IAQzB,eAAe,IAAI,aAAa;IAIvC,OAAO,CAAC,wBAAwB;YAgClB,UAAU;IAuBjB,QAAQ,IAAI,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC;IAOjC,cAAc,IAAI,MAAM,CAAC,MAAM,EAAE,KAAK,EAAE,CAAC;IAiBzC,gBAAgB,IAAI,KAAK,GAAG,SAAS;IAuB/B,UAAU,IAAI,OAAO,CAAC,kBAAkB,CAAC;CAQvD;AAOD,eAAO,MAAM,YAAY,UAChB,QAAQ,WACN,mBAAmB,KAC3B,QAAQ,cAAc,CAKxB,CAAC"}
@@ -105,8 +105,7 @@ export declare const BASE_REG_RETRY_TIMER_VAL_IN_SEC = 30;
105
105
  export declare const SEC_TO_MSEC_MFACTOR = 1000;
106
106
  export declare const MINUTES_TO_SEC_MFACTOR = 60;
107
107
  export declare const REG_RANDOM_T_FACTOR_UPPER_LIMIT = 10000;
108
- export declare const REG_TRY_BACKUP_TIMER_VAL_IN_SEC = 1200;
109
- export declare const REG_TRY_BACKUP_TIMER_VAL_FOR_CC_IN_SEC = 114;
108
+ export declare const REG_TRY_BACKUP_TIMER_VAL_IN_SEC = 114;
110
109
  export declare const REG_FAILBACK_429_MAX_RETRIES = 5;
111
110
  export declare const RETRY_TIMER_UPPER_LIMIT = 60;
112
111
  export declare const REGISTRATION_UTIL = "triggerRegistration";
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/CallingClient/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OA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