Skip to content

Commit

Permalink
chore(version): update version to 2.2.8
Browse files Browse the repository at this point in the history
  • Loading branch information
sanyamjain-plivo authored Sep 12, 2023
1 parent 5a0461f commit a977853
Show file tree
Hide file tree
Showing 44 changed files with 7,769 additions and 8,412 deletions.
1 change: 1 addition & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"plugins": ["@typescript-eslint"],
"rules": {
"quotes": "off",
"no-param-reassign": 0,
"@typescript-eslint/quotes": ["off"]
}
}
25 changes: 23 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,30 @@ All notable GA release changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## v2.2.7 (released@ 06-05-2022)
## v2.2.8 (released@ 11-09-2023)
**Bug Fixes**
* The call summary stats are not pushed to Plivo when the call is answered and hung up before the stats socket is open.

* Fixed: Corrected the handling of stir-verification in incoming call headers.
* Fixed: Fixed audio level discrepancies that occurred when changing input/output devices, ensuring accurate device settings.
* Fixed: Removed DOMError to support latest Typescript versions.
* Fixed: Restored functionality for incoming calls with PCMU codec.
* Fixed: Prevented SDK from logging out when re-registration timed out.
* Fixed: Reduced the time for firing the onConnectionChange event with a disconnected state to within 10 seconds when the SDK disconnects from Plivo servers, previously occurring within a 2-minute interval.


**Features**

* Added: A `refreshRegistrationTimer` flag for user-configurable periodic re-registration by the SDK.
* Added: An `onDtmfReceived` event triggered when the SDK receives DTMF tones.
* Added: Enhanced remote debugging with the collection and transmission of logs to Plivo servers.
* Added: Plivo STUN servers to ensure stable connections.
* Added: A `CALL_RINGING` event signaling the initiation of incoming/outgoing call ringing to Plivo.

## v2.2.7 (released@ 06-06-2022)
**Features**

* Added: New Client Region South-Asia to the existing Client Region list.
* Fixed: The call summary stats are not pushed to Plivo when the call is answered and hung up before the stats socket is open

## v2.2.6 (released@ 13-10-2021)
**Features**
Expand Down
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
@Library('plivo_standard_libs@websdk') _

websdkPipeline ([
buildContainer: 'plivo/jenkins-ci/plivo-websdk:master',
buildContainer: 'plivo/jenkins-ci/plivo-websdk:2cb1ecc',
disableLint: true
])
6 changes: 3 additions & 3 deletions ci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@ unitTests:
testsReportFile: nodejs.tests.report.xml
coverageReportFile: nodejs.coverage.report.xml
command: |
npm install
npm install --force
npm run test:unit-jenkins
integrationTests:
ignoreFailure: 'false'
nodejs:
testsReportFile: nodejs.inttests.report.xml
coverageReportFile: nodejs.intcoverage.report.xml
command: |
npm install
npm install --force
npm run test:integration
build:
nodejs:
command: npm install && npm run build
command: export NODE_OPTIONS=--openssl-legacy-provider && npm install --force && npm run build
outputDistDir: dist
140 changes: 126 additions & 14 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ declare module 'plivo-browser-sdk/client' {
allowMultipleIncomingCalls?: boolean;
closeProtection?: boolean;
maxAverageBitrate?: number;
registrationRefreshTimer?: number;
dtmfOptions?: DtmfOptions;
}
export interface BrowserDetails {
Expand Down Expand Up @@ -191,6 +192,56 @@ declare module 'plivo-browser-sdk/client' {
* @private
*/
password: null | string;
/**
* Access Token given when logging in
* @private
*/
accessToken: null | string;
/**
* Access Token object given when logging in
* @private
*/
accessTokenObject: null | any;
/**
* boolean that tells which type of login method is called
* @private
*/
isAccessTokenGenerator: boolean | null;
/**
* boolean that tells if user logged in through access token
* @private
*/
isAccessToken: boolean;
/**
* access token expiry
* @private
*/
accessTokenExpiryInEpoch: number | null;
/**
* Access Token Outgoing Grant
* @private
*/
isOutgoingGrant: boolean | null;
/**
* Access Token Incoming Grant
* @private
*/
isIncomingGrant: boolean | null;
/**
* Access Token abstract class that needs to be implemented
* @private
*/
accessTokenInterface: any;
/**
* Flag to monitor the feedback api that gets called after the token is expired
* @private
*/
deferFeedback: null | boolean;
/**
* Flag that tells if unregister is pending or not
* @private
*/
isUnregisterPending: null | boolean;
/**
* Options passed by the user while instantiating the client class
* @private
Expand Down Expand Up @@ -297,6 +348,11 @@ declare module 'plivo-browser-sdk/client' {
* @private
*/
plivoSocket: WebSocketInterface;
/**
* Holds the connection state of the SDK
* @private
*/
connectionState: string;
/**
* Responsible for playing audio stream of remote user during call
* @private
Expand Down Expand Up @@ -381,6 +437,21 @@ declare module 'plivo-browser-sdk/client' {
* @param {String} password
*/
login: (username: string, password: string) => boolean;
/**
* Register using user access token.
* @param {String} accessToken
*/
loginWithAccessToken: (accessToken: string) => boolean;
/**
* Register using user access token.
* @param {Any} accessTokenObject
*/
loginWithAccessTokenGenerator: (accessTokenObject: any) => boolean;
/**
* get error string by error code
* @param {number} errorCode
*/
getErrorStringByErrorCodes: (errorCode: number) => string;
/**
* Unregister and clear stats timer, socket.
*/
Expand Down Expand Up @@ -497,10 +568,13 @@ declare module 'plivo-browser-sdk/client' {
* @private
*/
constructor(options: ConfiguationOptions);
setExpiryTimeInEpoch: (timeInEpoch: number) => void;
getTokenExpiryTimeInEpoch: () => number | null;
}
}

declare module 'plivo-browser-sdk/logger' {
import { Client } from 'plivo-browser-sdk/client';
export type AvailableLogMethods = 'INFO' | 'DEBUG' | 'WARN' | 'ERROR' | 'ALL' | 'OFF' | 'ALL-PLAIN';
export type AvailableFlagValues = 'ALL' | 'NONE' | 'REMOTEONLY' | 'LOCALONLY';
export interface DtmfOptions {
Expand Down Expand Up @@ -528,6 +602,10 @@ declare module 'plivo-browser-sdk/logger' {
* @param {AvailableLogMethods} debugLevel - passed by user while initializing client
*/
enableSipLogs: (debugLevel: AvailableLogMethods) => void;
/**
* Send logs to Plivo kibana.
*/
send: (client: Client) => void;
}
export const Logger: PlivoLogger;
export {};
Expand All @@ -547,13 +625,15 @@ declare module 'plivo-browser-sdk/managers/callSession' {
extraHeaders: ExtraHeaders;
call_initiation_time?: number;
client: Client;
stirShakenState: string;
}
export interface CallInfo {
callUUID: string;
direction: string;
src: string;
dest: string;
state: string;
stirShakenState: string;
extraHeaders: ExtraHeaders;
}
export interface SignallingInfo {
Expand Down Expand Up @@ -599,6 +679,11 @@ declare module 'plivo-browser-sdk/managers/callSession' {
* @private
*/
callUUID: string | null;
/**
* call signed or not it will have these options ‘verified’ | ‘not_verified’ | ‘Not_applicable’
* @private
*/
stirShakenState: string;
/**
* Identifier generated by JSSIP when a new RTCSession is created for the call
* @private
Expand Down Expand Up @@ -724,6 +809,11 @@ declare module 'plivo-browser-sdk/managers/callSession' {
* @param {Client} clientObject - client reference
*/
onAccepted: (cs: Client) => void;
/**
* Triggered when the user answers the call(Outgoing/Incoming) and got or received 200 OK.
* @param {Client} clientObject - client reference
*/
onRinging: (cs: Client) => void;
/**
* Triggered when the user answers the call(Outgoing/Incoming) and got or received ACK.
* @param {Client} clientObject - client reference
Expand Down Expand Up @@ -758,15 +848,15 @@ declare module 'plivo-browser-sdk/managers/callSession' {
* @param {Client} clientObject - client reference
* @param {Error} err - reason for issue
*/
onGetUserMediaFailed: (cs: Client, error: Error | DOMError) => void;
onGetUserMediaFailed: (cs: Client, error: Error) => void;
/**
* Triggered when peer connection issues(creating offer, answer and setting description) occur.
* @param {Client} clientObject - client reference
* @param {String} msg - type of issue
* @param {Function} callStatscb - callstats.io callback for each issue
* @param {Error} err - reason for issue
*/
handlePeerConnectionFailures: (cs: Client, msg: string | Error | DOMError, callStatscb: () => void, err: Error | DOMError) => void;
handlePeerConnectionFailures: (cs: Client, msg: string | Error, callStatscb: () => void, err: Error) => void;
/**
* @constructor
* @param {CallSessionOptions} options - call(Outgoing/Incoming) information
Expand Down Expand Up @@ -893,18 +983,6 @@ declare module 'plivo-browser-sdk/media/audioDevice' {
* Stopping the requesting frame. It would stop emitting the real time audio levels.
*/
export const stopVolumeDataStreaming: () => void;
/**
* Add getters and setters for input audio devices.
*/
export const inputDevices: InputDevices;
/**
* Add getters and setters for output audio devices.
*/
export const outputDevices: OutputDevices;
/**
* Add getters and setters for ringtone which is played during the call.
*/
export const ringtoneDevices: RingToneDevices;
/**
* Add audio device information whenever device is changed.
* @param {Boolean} store - pass true to store information in Client object for reference
Expand Down Expand Up @@ -936,6 +1014,18 @@ declare module 'plivo-browser-sdk/media/audioDevice' {
* Check if input or output audio device has changed.
*/
export const checkAudioDevChange: () => void;
/**
* Add getters and setters for input audio devices.
*/
export const inputDevices: InputDevices;
/**
* Add getters and setters for output audio devices.
*/
export const outputDevices: OutputDevices;
/**
* Add getters and setters for ringtone which is played during the call.
*/
export const ringtoneDevices: RingToneDevices;
/**
* Unmute the local stream.
*/
Expand Down Expand Up @@ -1196,6 +1286,27 @@ declare module 'plivo-browser-sdk/stats/nonRTPStats' {
activeInputAudioDevice: string;
activeOutputAudioDevice: string;
}
export interface RingingEvent {
msg: string;
userAgent: string;
clientVersionMajor: string;
clientVersionMinor: string;
clientVersionPatch: string;
sdkName: string;
sdkVersionMajor: number;
sdkVersionMinor: number;
sdkVersionPatch: number;
clientName: string;
devicePlatform: string;
deviceOs: string;
setupOptions: ConfiguationOptions;
signalling?: any;
mediaConnection?: any;
audioDeviceInfo?: DeviceAudioInfo;
isAudioDeviceToggled?: boolean;
isNetworkChanged?: boolean;
jsFramework: string[];
}
export interface SummaryEvent {
msg: string;
userAgent: string;
Expand Down Expand Up @@ -1252,6 +1363,7 @@ declare module 'plivo-browser-sdk/stats/nonRTPStats' {
* @param {CallSession} session - call session information
*/
export const sendCallSummaryEvent: (deviceInfo: DeviceAudioInfo, signallingInfo: SignallingInfo, mediaConnectionInfo: MediaConnectionInformation, session: CallSession) => void;
export const sendCallRingingEvent: (deviceInfo: DeviceAudioInfo, signallingInfo: SignallingInfo, mediaConnectionInfo: MediaConnectionInformation, session: CallSession) => void;
/**
* Send user feedback to plivo stats.
* @param {CallSession} callSession - call information
Expand Down
1 change: 1 addition & 0 deletions karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ module.exports = function (config) {
},
},
client: {
captureConsole: true,
mocha: {
timeout: '60000'
},
Expand Down
Loading

0 comments on commit a977853

Please sign in to comment.