eyevinn-channel-engine 4.0.3 → 4.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.
@@ -21,6 +21,7 @@ export interface ChannelEngineOpts {
21
21
  forceTargetDuration?: boolean;
22
22
  adCopyMgrUri?: string;
23
23
  adXchangeUri?: string;
24
+ noSessionDataTags?: boolean;
24
25
  }
25
26
  export interface VodRequest {
26
27
  sessionId: string;
@@ -406,6 +406,7 @@ var ChannelEngine = /** @class */ (function () {
406
406
  averageSegmentDuration: channel.options && channel.options.averageSegmentDuration ? channel.options.averageSegmentDuration : this.streamerOpts.defaultAverageSegmentDuration,
407
407
  useDemuxedAudio: options.useDemuxedAudio,
408
408
  alwaysNewSegments: options.alwaysNewSegments,
409
+ noSessionDataTags: options.noSessionDataTags,
409
410
  playheadDiffThreshold: channel.options && channel.options.playheadDiffThreshold ? channel.options.playheadDiffThreshold : this.streamerOpts.defaultPlayheadDiffThreshold,
410
411
  maxTickInterval: channel.options && channel.options.maxTickInterval ? channel.options.maxTickInterval : this.streamerOpts.defaultMaxTickInterval,
411
412
  targetDurationPadding: channel.options && channel.options.targetDurationPadding ? channel.options.targetDurationPadding : this.streamerOpts.targetDurationPadding,
@@ -49,6 +49,7 @@ declare class Session {
49
49
  _sessionProfile: any;
50
50
  _audioTracks: any;
51
51
  _closedCaptions: any;
52
+ _noSessionDataTags: any;
52
53
  slateUri: any;
53
54
  slateRepetitions: any;
54
55
  slateDuration: any;
@@ -124,6 +124,9 @@ var Session = /** @class */ (function () {
124
124
  if (config.closedCaptions) {
125
125
  this._closedCaptions = config.closedCaptions;
126
126
  }
127
+ if (config.noSessionDataTags) {
128
+ this._noSessionDataTags = config.noSessionDataTags;
129
+ }
127
130
  if (config.slateUri) {
128
131
  this.slateUri = config.slateUri;
129
132
  this.slateRepetitions = config.slateRepetitions || 10;
@@ -1367,8 +1370,10 @@ var Session = /** @class */ (function () {
1367
1370
  m3u8 = "#EXTM3U\n";
1368
1371
  m3u8 += "#EXT-X-VERSION:4\n";
1369
1372
  m3u8 += m3u8Header(this._instanceId);
1370
- m3u8 += "#EXT-X-SESSION-DATA:DATA-ID=\"eyevinn.tv.session.id\",VALUE=\"".concat(this._sessionId, "\"\n");
1371
- m3u8 += "#EXT-X-SESSION-DATA:DATA-ID=\"eyevinn.tv.eventstream\",VALUE=\"/eventstream/".concat(this._sessionId, "\"\n");
1373
+ if (!this._noSessionDataTags) {
1374
+ m3u8 += "#EXT-X-SESSION-DATA:DATA-ID=\"eyevinn.tv.session.id\",VALUE=\"".concat(this._sessionId, "\"\n");
1375
+ m3u8 += "#EXT-X-SESSION-DATA:DATA-ID=\"eyevinn.tv.eventstream\",VALUE=\"/eventstream/".concat(this._sessionId, "\"\n");
1376
+ }
1372
1377
  return [4 /*yield*/, this._sessionState.getCurrentVod()];
1373
1378
  case 1:
1374
1379
  currentVod = _a.sent();
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eyevinn-channel-engine",
3
- "version": "4.0.3",
3
+ "version": "4.0.4",
4
4
  "description": "OTT TV Channel Engine",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/engine/server.ts CHANGED
@@ -46,6 +46,7 @@ export interface ChannelEngineOpts {
46
46
  forceTargetDuration?: boolean;
47
47
  adCopyMgrUri?: string; // deprecated
48
48
  adXchangeUri?: string; // deprecated
49
+ noSessionDataTags?: boolean;
49
50
  }
50
51
 
51
52
  interface StreamerOpts {
@@ -396,6 +397,7 @@ export class ChannelEngine {
396
397
  averageSegmentDuration: channel.options && channel.options.averageSegmentDuration ? channel.options.averageSegmentDuration : this.streamerOpts.defaultAverageSegmentDuration,
397
398
  useDemuxedAudio: options.useDemuxedAudio,
398
399
  alwaysNewSegments: options.alwaysNewSegments,
400
+ noSessionDataTags: options.noSessionDataTags,
399
401
  playheadDiffThreshold: channel.options && channel.options.playheadDiffThreshold ? channel.options.playheadDiffThreshold : this.streamerOpts.defaultPlayheadDiffThreshold,
400
402
  maxTickInterval: channel.options && channel.options.maxTickInterval ? channel.options.maxTickInterval : this.streamerOpts.defaultMaxTickInterval,
401
403
  targetDurationPadding: channel.options && channel.options.targetDurationPadding ? channel.options.targetDurationPadding : this.streamerOpts.targetDurationPadding,
package/engine/session.js CHANGED
@@ -97,6 +97,9 @@ class Session {
97
97
  if (config.closedCaptions) {
98
98
  this._closedCaptions = config.closedCaptions;
99
99
  }
100
+ if (config.noSessionDataTags) {
101
+ this._noSessionDataTags = config.noSessionDataTags;
102
+ }
100
103
  if (config.slateUri) {
101
104
  this.slateUri = config.slateUri;
102
105
  this.slateRepetitions = config.slateRepetitions || 10;
@@ -952,8 +955,10 @@ class Session {
952
955
  let m3u8 = "#EXTM3U\n";
953
956
  m3u8 += "#EXT-X-VERSION:4\n";
954
957
  m3u8 += m3u8Header(this._instanceId);
955
- m3u8 += `#EXT-X-SESSION-DATA:DATA-ID="eyevinn.tv.session.id",VALUE="${this._sessionId}"\n`;
956
- m3u8 += `#EXT-X-SESSION-DATA:DATA-ID="eyevinn.tv.eventstream",VALUE="/eventstream/${this._sessionId}"\n`;
958
+ if (!this._noSessionDataTags) {
959
+ m3u8 += `#EXT-X-SESSION-DATA:DATA-ID="eyevinn.tv.session.id",VALUE="${this._sessionId}"\n`;
960
+ m3u8 += `#EXT-X-SESSION-DATA:DATA-ID="eyevinn.tv.eventstream",VALUE="/eventstream/${this._sessionId}"\n`;
961
+ }
957
962
  const currentVod = await this._sessionState.getCurrentVod();
958
963
  if (!currentVod) {
959
964
  throw new Error('Session not ready');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eyevinn-channel-engine",
3
- "version": "4.0.3",
3
+ "version": "4.0.4",
4
4
  "description": "OTT TV Channel Engine",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",