eyevinn-channel-engine 5.0.3 → 5.0.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/engine/server.d.ts +1 -0
- package/dist/engine/server.js +2 -1
- package/dist/engine/session.d.ts +1 -0
- package/dist/engine/session.js +12 -4
- package/dist/package.json +3 -3
- package/engine/server.ts +3 -1
- package/engine/session.js +13 -6
- package/package.json +3 -3
package/dist/engine/server.d.ts
CHANGED
package/dist/engine/server.js
CHANGED
|
@@ -462,7 +462,8 @@ var ChannelEngine = /** @class */ (function () {
|
|
|
462
462
|
slateRepetitions: channel.slate && channel.slate.repetitions ? channel.slate.repetitions : this.slateRepetitions,
|
|
463
463
|
slateDuration: channel.slate && channel.slate.duration ? channel.slate.duration : this.slateDuration,
|
|
464
464
|
cloudWatchMetrics: this.logCloudWatchMetrics,
|
|
465
|
-
sessionEventStream: options.sessionEventStream
|
|
465
|
+
sessionEventStream: options.sessionEventStream,
|
|
466
|
+
rollingPDT: options.rollingPDT
|
|
466
467
|
}, this.sessionStore);
|
|
467
468
|
sessionsLive[channel.id] = new SessionLive({
|
|
468
469
|
sessionId: channel.id,
|
package/dist/engine/session.d.ts
CHANGED
package/dist/engine/session.js
CHANGED
|
@@ -137,6 +137,7 @@ var Session = /** @class */ (function () {
|
|
|
137
137
|
this.partialStoreHLSVod = null;
|
|
138
138
|
this.currentPlayheadRef = null;
|
|
139
139
|
this.disableLegacyMasterManifestFormat = null;
|
|
140
|
+
this.rollingPDT = null;
|
|
140
141
|
if (config) {
|
|
141
142
|
if (config.alwaysNewSegments) {
|
|
142
143
|
this.alwaysNewSegments = config.alwaysNewSegments;
|
|
@@ -147,6 +148,9 @@ var Session = /** @class */ (function () {
|
|
|
147
148
|
if (config.partialStoreHLSVod) {
|
|
148
149
|
this.partialStoreHLSVod = config.partialStoreHLSVod;
|
|
149
150
|
}
|
|
151
|
+
if (config.rollingPDT) {
|
|
152
|
+
this.rollingPDT = config.rollingPDT;
|
|
153
|
+
}
|
|
150
154
|
if (config.alwaysMapBandwidthByNearest) {
|
|
151
155
|
this.alwaysMapBandwidthByNearest = config.alwaysMapBandwidthByNearest;
|
|
152
156
|
}
|
|
@@ -1749,7 +1753,8 @@ var Session = /** @class */ (function () {
|
|
|
1749
1753
|
shouldContainSubtitles: this.use_vtt_subtitles,
|
|
1750
1754
|
expectedSubtitleTracks: this._subtitleTracks,
|
|
1751
1755
|
alwaysMapBandwidthByNearest: this.alwaysMapBandwidthByNearest,
|
|
1752
|
-
skipSerializeMediaSequences: this.partialStoreHLSVod
|
|
1756
|
+
skipSerializeMediaSequences: this.partialStoreHLSVod,
|
|
1757
|
+
calculatePDT: this.rollingPDT
|
|
1753
1758
|
};
|
|
1754
1759
|
newVod = new HLSVod(vodResponse.uri, [], vodResponse.unixTs, vodResponse.offset * 1000, m3u8Header(this._instanceId), hlsOpts);
|
|
1755
1760
|
if (vodResponse.timedMetadata) {
|
|
@@ -1981,7 +1986,8 @@ var Session = /** @class */ (function () {
|
|
|
1981
1986
|
shouldContainSubtitles: this.use_vtt_subtitles,
|
|
1982
1987
|
expectedSubtitleTracks: this._subtitleTracks,
|
|
1983
1988
|
alwaysMapBandwidthByNearest: this.alwaysMapBandwidthByNearest,
|
|
1984
|
-
skipSerializeMediaSequences: this.partialStoreHLSVod
|
|
1989
|
+
skipSerializeMediaSequences: this.partialStoreHLSVod,
|
|
1990
|
+
calculatePDT: this.rollingPDT
|
|
1985
1991
|
};
|
|
1986
1992
|
newVod = new HLSVod(vodResponse.uri, null, vodResponse.unixTs, vodResponse.offset * 1000, m3u8Header(this._instanceId), hlsOpts);
|
|
1987
1993
|
if (vodResponse.timedMetadata) {
|
|
@@ -2392,7 +2398,8 @@ var Session = /** @class */ (function () {
|
|
|
2392
2398
|
shouldContainSubtitles: _this.use_vtt_subtitles,
|
|
2393
2399
|
expectedSubtitleTracks: _this._subtitleTracks,
|
|
2394
2400
|
alwaysMapBandwidthByNearest: _this.alwaysMapBandwidthByNearest,
|
|
2395
|
-
skipSerializeMediaSequences: _this.partialStoreHLSVod
|
|
2401
|
+
skipSerializeMediaSequences: _this.partialStoreHLSVod,
|
|
2402
|
+
calculatePDT: _this.rollingPDT
|
|
2396
2403
|
};
|
|
2397
2404
|
var timestamp = Date.now();
|
|
2398
2405
|
hlsVod_1 = new HLSVod(_this.slateUri, null, timestamp, null, m3u8Header(_this._instanceId), hlsOpts);
|
|
@@ -2519,7 +2526,8 @@ var Session = /** @class */ (function () {
|
|
|
2519
2526
|
shouldContainSubtitles: _this.use_vtt_subtitles,
|
|
2520
2527
|
expectedSubtitleTracks: _this._subtitleTracks,
|
|
2521
2528
|
alwaysMapBandwidthByNearest: _this.alwaysMapBandwidthByNearest,
|
|
2522
|
-
skipSerializeMediaSequences: _this.partialStoreHLSVod
|
|
2529
|
+
skipSerializeMediaSequences: _this.partialStoreHLSVod,
|
|
2530
|
+
calculatePDT: _this.rollingPDT
|
|
2523
2531
|
};
|
|
2524
2532
|
var timestamp = Date.now();
|
|
2525
2533
|
hlsVod_2 = new HLSVod(nexVodUri, null, timestamp, null, m3u8Header(_this._instanceId), hlsOpts);
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eyevinn-channel-engine",
|
|
3
|
-
"version": "5.0.
|
|
3
|
+
"version": "5.0.4",
|
|
4
4
|
"description": "OTT TV Channel Engine",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@eyevinn/hls-repeat": "^0.2.1",
|
|
33
33
|
"@eyevinn/hls-truncate": "^0.3.3",
|
|
34
|
-
"@eyevinn/hls-vodtolive": "^4.1.
|
|
34
|
+
"@eyevinn/hls-vodtolive": "^4.1.8",
|
|
35
35
|
"@eyevinn/m3u8": "^0.5.6",
|
|
36
|
-
"@fastify/static": "^
|
|
36
|
+
"@fastify/static": "^8.1.1",
|
|
37
37
|
"abort-controller": "^3.0.0",
|
|
38
38
|
"debug": "^3.2.7",
|
|
39
39
|
"fastify": "^3.29.0",
|
package/engine/server.ts
CHANGED
|
@@ -65,6 +65,7 @@ export interface ChannelEngineOpts {
|
|
|
65
65
|
keepAliveTimeout?: number;
|
|
66
66
|
sessionEventStream?: boolean;
|
|
67
67
|
sessionHealthKey?: string;
|
|
68
|
+
rollingPDT?: boolean;
|
|
68
69
|
}
|
|
69
70
|
|
|
70
71
|
interface StreamerOpts {
|
|
@@ -499,7 +500,8 @@ export class ChannelEngine {
|
|
|
499
500
|
slateRepetitions: channel.slate && channel.slate.repetitions ? channel.slate.repetitions : this.slateRepetitions,
|
|
500
501
|
slateDuration: channel.slate && channel.slate.duration ? channel.slate.duration : this.slateDuration,
|
|
501
502
|
cloudWatchMetrics: this.logCloudWatchMetrics,
|
|
502
|
-
sessionEventStream: options.sessionEventStream
|
|
503
|
+
sessionEventStream: options.sessionEventStream,
|
|
504
|
+
rollingPDT: options.rollingPDT
|
|
503
505
|
}, this.sessionStore);
|
|
504
506
|
|
|
505
507
|
sessionsLive[channel.id] = new SessionLive({
|
package/engine/session.js
CHANGED
|
@@ -87,6 +87,7 @@ class Session {
|
|
|
87
87
|
this.partialStoreHLSVod = null;
|
|
88
88
|
this.currentPlayheadRef = null;
|
|
89
89
|
this.disableLegacyMasterManifestFormat = null;
|
|
90
|
+
this.rollingPDT = null;
|
|
90
91
|
if (config) {
|
|
91
92
|
if (config.alwaysNewSegments) {
|
|
92
93
|
this.alwaysNewSegments = config.alwaysNewSegments;
|
|
@@ -97,7 +98,9 @@ class Session {
|
|
|
97
98
|
if (config.partialStoreHLSVod) {
|
|
98
99
|
this.partialStoreHLSVod = config.partialStoreHLSVod;
|
|
99
100
|
}
|
|
100
|
-
|
|
101
|
+
if (config.rollingPDT) {
|
|
102
|
+
this.rollingPDT = config.rollingPDT;
|
|
103
|
+
}
|
|
101
104
|
if (config.alwaysMapBandwidthByNearest) {
|
|
102
105
|
this.alwaysMapBandwidthByNearest = config.alwaysMapBandwidthByNearest;
|
|
103
106
|
}
|
|
@@ -1273,7 +1276,8 @@ class Session {
|
|
|
1273
1276
|
shouldContainSubtitles: this.use_vtt_subtitles,
|
|
1274
1277
|
expectedSubtitleTracks: this._subtitleTracks,
|
|
1275
1278
|
alwaysMapBandwidthByNearest: this.alwaysMapBandwidthByNearest,
|
|
1276
|
-
skipSerializeMediaSequences: this.partialStoreHLSVod
|
|
1279
|
+
skipSerializeMediaSequences: this.partialStoreHLSVod,
|
|
1280
|
+
calculatePDT: this.rollingPDT
|
|
1277
1281
|
};
|
|
1278
1282
|
newVod = new HLSVod(vodResponse.uri, [], vodResponse.unixTs, vodResponse.offset * 1000, m3u8Header(this._instanceId), hlsOpts);
|
|
1279
1283
|
if (vodResponse.timedMetadata) {
|
|
@@ -1458,7 +1462,8 @@ class Session {
|
|
|
1458
1462
|
shouldContainSubtitles: this.use_vtt_subtitles,
|
|
1459
1463
|
expectedSubtitleTracks: this._subtitleTracks,
|
|
1460
1464
|
alwaysMapBandwidthByNearest: this.alwaysMapBandwidthByNearest,
|
|
1461
|
-
skipSerializeMediaSequences: this.partialStoreHLSVod
|
|
1465
|
+
skipSerializeMediaSequences: this.partialStoreHLSVod,
|
|
1466
|
+
calculatePDT: this.rollingPDT
|
|
1462
1467
|
};
|
|
1463
1468
|
newVod = new HLSVod(vodResponse.uri, null, vodResponse.unixTs, vodResponse.offset * 1000, m3u8Header(this._instanceId), hlsOpts);
|
|
1464
1469
|
if (vodResponse.timedMetadata) {
|
|
@@ -1771,7 +1776,6 @@ class Session {
|
|
|
1771
1776
|
try {
|
|
1772
1777
|
const slateVod = new HLSRepeatVod(this.slateUri, reps || this.slateRepetitions);
|
|
1773
1778
|
let hlsVod;
|
|
1774
|
-
|
|
1775
1779
|
slateVod.load()
|
|
1776
1780
|
.then(() => {
|
|
1777
1781
|
const hlsOpts = {
|
|
@@ -1782,7 +1786,8 @@ class Session {
|
|
|
1782
1786
|
shouldContainSubtitles: this.use_vtt_subtitles,
|
|
1783
1787
|
expectedSubtitleTracks: this._subtitleTracks,
|
|
1784
1788
|
alwaysMapBandwidthByNearest: this.alwaysMapBandwidthByNearest,
|
|
1785
|
-
skipSerializeMediaSequences: this.partialStoreHLSVod
|
|
1789
|
+
skipSerializeMediaSequences: this.partialStoreHLSVod,
|
|
1790
|
+
calculatePDT: this.rollingPDT
|
|
1786
1791
|
};
|
|
1787
1792
|
const timestamp = Date.now();
|
|
1788
1793
|
hlsVod = new HLSVod(this.slateUri, null, timestamp, null, m3u8Header(this._instanceId), hlsOpts);
|
|
@@ -1896,6 +1901,7 @@ class Session {
|
|
|
1896
1901
|
|
|
1897
1902
|
slateVod.load()
|
|
1898
1903
|
.then(() => {
|
|
1904
|
+
|
|
1899
1905
|
const hlsOpts = {
|
|
1900
1906
|
sequenceAlwaysContainNewSegments: this.alwaysNewSegments,
|
|
1901
1907
|
forcedDemuxMode: this.use_demuxed_audio,
|
|
@@ -1904,7 +1910,8 @@ class Session {
|
|
|
1904
1910
|
shouldContainSubtitles: this.use_vtt_subtitles,
|
|
1905
1911
|
expectedSubtitleTracks: this._subtitleTracks,
|
|
1906
1912
|
alwaysMapBandwidthByNearest: this.alwaysMapBandwidthByNearest,
|
|
1907
|
-
skipSerializeMediaSequences: this.partialStoreHLSVod
|
|
1913
|
+
skipSerializeMediaSequences: this.partialStoreHLSVod,
|
|
1914
|
+
calculatePDT: this.rollingPDT
|
|
1908
1915
|
};
|
|
1909
1916
|
const timestamp = Date.now();
|
|
1910
1917
|
hlsVod = new HLSVod(nexVodUri, null, timestamp, null, m3u8Header(this._instanceId), hlsOpts);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eyevinn-channel-engine",
|
|
3
|
-
"version": "5.0.
|
|
3
|
+
"version": "5.0.4",
|
|
4
4
|
"description": "OTT TV Channel Engine",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@eyevinn/hls-repeat": "^0.2.1",
|
|
33
33
|
"@eyevinn/hls-truncate": "^0.3.3",
|
|
34
|
-
"@eyevinn/hls-vodtolive": "^4.1.
|
|
34
|
+
"@eyevinn/hls-vodtolive": "^4.1.8",
|
|
35
35
|
"@eyevinn/m3u8": "^0.5.6",
|
|
36
|
-
"@fastify/static": "^
|
|
36
|
+
"@fastify/static": "^8.1.1",
|
|
37
37
|
"abort-controller": "^3.0.0",
|
|
38
38
|
"debug": "^3.2.7",
|
|
39
39
|
"fastify": "^3.29.0",
|