Upgrade from V2.2.X to V2.3.0
This topic describes how to upgrade the production studio Web SDK from V2.2.X to V2.3.0 and lists the major changes in the new version.
Background information
Version 2.3.0 of the production studio Web SDK is now available. This version adds a carousel feature to the console and includes performance and user experience optimizations. If you are using V2.2.X, you can upgrade to V2.3.0 by following the instructions in this topic.
You may encounter compatibility issues if you continue to use V2.2.X. We recommend that you upgrade to V2.3.0.
Compared with previous versions, the main changes in V2.3.0 are as follows:
Resource reference and integration flow
The main software development kit (SDK) (Caster-next) is upgraded to V2.3.0. This upgrade includes updated CSS and JS resources.
The player solution is upgraded. You must update the dependencies by removing
adapter.min.js, artc.jsand addingaliplayer-min.css, aliplayer-min.js.
API operations
V2.3.0 adds new API operations to support production studios in playlist mode. For more information, see ApsaraVideo Live API overview.
Upgrade steps
Modify the JS and CSS resource references as shown in the following code.
<!doctype html> <html> <head> <meta charset="utf-8" /> <title>Your App</title> <!-- Production studio stylesheet --> <link rel="stylesheet" href="https://g.alicdn.com/cdn-fe/caster-next/2.3.0/index.css" /> <link rel="stylesheet" href="https://g.alicdn.com/de/prismplayer/2.9.12/skins/default/aliplayer-min.css"> </head> <body> <!-- The element to which the production studio is attached --> <div id="caster-root"></div> <!-- Player script --> <script src="https://g.alicdn.com/de/prismplayer/2.9.12/aliplayer-min.js"></script> <!-- Production studio SDK script --> <script src="https://g.alicdn.com/cdn-fe/caster-next/2.3.0/index.js"></script> </body> </html>In the
new Caster()initialization code, add theUseRtsparameter and set its value totrue. For more information about the upgraded initialization code, see Initialize the SDK.Update the API operations. To use the production studio in playlist mode, call the following new API operations:
export interface ServicesImp { // Product: ApsaraVideo Live (LIVE), production studio service API: https://help.aliyun.com/document_detail/60293.html#title-fjq-f1t-5qz DescribeShowList: (...args: any[]) => Promise<Resp>; AddShowIntoShowList: (...args: any[]) => Promise<Resp>; RemoveShowFromShowList: (...args: any[]) => Promise<Resp>; ModifyShowList: (...args: any[]) => Promise<Resp>; PlayChoosenShow: (...args: any[]) => Promise<Resp>; // Product: ApsaraVideo VOD (VOD), API documentation: https://help.aliyun.com/document_detail/60574.html GetImageInfo: (...args: any[]) => Promise<Resp>; GetVideoInfos: (...args: any[]) => Promise<Resp>; }