# Dynamic SMIL not working

**URL:** <https://community.wowza.com/t/dynamic-smil-not-working/47330>\
**Category:** Wowza Streaming Engine\
**Created:** [August 9, 2016, 3:18am UTC](https://community.wowza.com/t/dynamic-smil-not-working/47330 "2016-08-09T03:18:31Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jagir\_Highq](https://avatars.discourse-cdn.com/v4/letter/j/c37758/32.png) [@Jagir\_Highq](https://community.wowza.com/u/Jagir_Highq)\
**Post date:** [August 9, 2016, 3:18am UTC](https://community.wowza.com/t/dynamic-smil-not-working/47330/1 "2016-08-09T03:18:31Z")

</div>

Hello,

I am trying to generate smil file dynamically , but somehow it not works for me.

I am creating one j2ee web project.

Below is my code :

HTML code

=========

Java code

========

package com.jagir.wowza.smil;

import com.wowza.wms.application.IApplicationInstance;

import com.wowza.wms.medialist.MediaList;

import com.wowza.wms.medialist.MediaListRendition;

import com.wowza.wms.medialist.MediaListSegment;

import com.wowza.wms.module.ModuleBase;

import com.wowza.wms.stream.IMediaListProvider;

import com.wowza.wms.stream.IMediaListReader;

import com.wowza.wms.stream.IMediaStream;

public class ModuleAMLSTTest extends ModuleBase

{

class MyMediaListProvider implements IMediaListProvider

{

public MediaList resolveMediaList(IMediaListReader mediaListReader, IMediaStream stream, String streamName)

{

MediaList mediaList = new MediaList();

MediaListSegment segment = new MediaListSegment();

mediaList.addSegment(segment);

MediaListRendition rendition1 = new MediaListRendition();

segment.addRendition(rendition1);

rendition1.setName(“mp4:”+streamName+"\_450.mp4");

rendition1.setBitrateAudio(44100);

rendition1.setBitrateVideo(45000);

rendition1.setWidth(424);

rendition1.setHeight(240);

rendition1.setAudioCodecId(“mp4a.40.2”);

rendition1.setVideoCodecId(“avc1.66.12”);

MediaListRendition rendition2 = new MediaListRendition();

segment.addRendition(rendition2);

rendition2.setName(“mp4:”+streamName+"\_750.mp4");

rendition2.setBitrateAudio(44100);

rendition2.setBitrateVideo(750000);

rendition2.setWidth(640);

rendition2.setHeight(480);

rendition2.setAudioCodecId(“mp4a.40.2”);

rendition2.setVideoCodecId(“avc1.77.31”);

MediaListRendition rendition3 = new MediaListRendition();

segment.addRendition(rendition3);

rendition3.setName(“mp4:”+streamName+"\_1100.mp4");

rendition3.setBitrateAudio(44100);

rendition3.setBitrateVideo(1100000);

rendition3.setWidth(1272);

rendition3.setHeight(720);

rendition3.setAudioCodecId(“mp4a.40.2”);

rendition3.setVideoCodecId(“avc1.77.31”);

MediaListRendition rendition4 = new MediaListRendition();

segment.addRendition(rendition4);

rendition4.setName(“mp4:”+streamName+"\_1500.mp4");

rendition4.setBitrateAudio(44100);

rendition4.setBitrateVideo(1100000);

rendition4.setWidth(1272);

rendition4.setHeight(720);

rendition4.setAudioCodecId(“mp4a.40.2”);

rendition4.setVideoCodecId(“avc1.77.31”);

System.out.println("::::::::::::::::::::::"+streamName);

return mediaList;

}

}

public void onAppStart(IApplicationInstance appInstance)

{

appInstance.setMediaListProvider(new MyMediaListProvider());

}

}

bigbuckbunny\_450.mp4

bigbuckbunny\_750.mp4

bigbuckbunny\_1100.mp4

bigbuckbunny\_1500.mp4

files are stored in content folder.

I have also added

ModuleAMLSTTest

ModuleAMLSTTest

com.jagir.wowza.smil.ModuleAMLSTTest

to

C:\Program Files (x86)\Wowza Media Systems\Wowza Streaming Engine 4.5.0\conf\vod\Application.xml

---

<div class="post-metadata">

**Author:** ![sal\_jefferson](https://avatars.discourse-cdn.com/v4/letter/s/6de8d8/32.png) [@sal\_jefferson](https://community.wowza.com/u/sal_jefferson)\
**Post date:** [August 9, 2016, 8:20am UTC](https://community.wowza.com/t/dynamic-smil-not-working/47330/2 "2016-08-09T08:20:16Z")

</div>

Are you seeing any indication of the problem in the error logs? Can you start Wowza in stand-alone mode and view the log output in the console?

Regards,

Salvadore

---

<div class="post-metadata">

**Author:** ![sal\_jefferson](https://avatars.discourse-cdn.com/v4/letter/s/6de8d8/32.png) [@sal\_jefferson](https://community.wowza.com/u/sal_jefferson)\
**Post date:** [August 9, 2016, 5:51pm UTC](https://community.wowza.com/t/dynamic-smil-not-working/47330/3 "2016-08-09T17:51:40Z")

</div>

Are you using the Wowza IDE to compile this module?

If so, please confirm that the jar for this module has been compiled to the [install-dir]/lib folder in your Wowza installation folder.

If not, you need to be using the Wowza IDE:

[How to extend Wowza Streaming Engine using the Wowza IDE](https://www.wowza.com/docs/how-to-extend-wowza-streaming-engine-using-the-wowza-ide)

Regards,

Salvadore

---

<div class="post-metadata">

**Author:** ![sal\_jefferson](https://avatars.discourse-cdn.com/v4/letter/s/6de8d8/32.png) [@sal\_jefferson](https://community.wowza.com/u/sal_jefferson)\
**Post date:** [August 10, 2016, 5:50am UTC](https://community.wowza.com/t/dynamic-smil-not-working/47330/4 "2016-08-10T05:50:20Z")

</div>

Thats great news! Thanks for the update and glad you got this working.

Regards,

Salvadore

---

<div class="post-metadata">

**Author:** ![Jagir\_Highq](https://avatars.discourse-cdn.com/v4/letter/j/c37758/32.png) [@Jagir\_Highq](https://community.wowza.com/u/Jagir_Highq)\
**Post date:** [August 9, 2016, 7:07am UTC](https://community.wowza.com/t/dynamic-smil-not-working/47330/5 "2016-08-09T07:07:10Z")

</div>

wowzastreamingengine\_error.log

================================

WARN server comment 2016-08-09 20:34:56 - - - - - 16846.869 - - - - - - - - loadModFunctions[vod/_definst_]: Module class not found or could not be loaded. Check [install-dir]/conf/vod/Application.xml to be sure all Modules/Module/Class paths are correct: name:ModuleAMLSTTest class:com.jagir.wowza.smil.ModuleAMLSTTest

WARN server comment 2016-08-09 20:34:56 - - - - - 0.024 - - - - - - - - HTTPStreamerCupertinoIndexPlaylist.indexFile[vod/_definst_/amlst:bigbuckbunny]: MediaList is empty.

wowzastreamengine\_access.log

======================================

2016-08-09 20:34:56 IST comment server WARN 200 - loadModFunctions[vod/_definst_]: Module class not found or could not be loaded. Check [install-dir]/conf/vod/Application.xml to be sure all Modules/Module/Class paths are correct: name:ModuleAMLSTTest class:com.jagir.wowza.smil.ModuleAMLSTTest - - - 16846.869 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:34:56 IST comment server INFO 200 - MediaCasterStreamValidator.init[vod/_definst_]: Started - - - 16846.877 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:34:56 IST comment server INFO 200 - ModuleCoreSecurity.onAppStart[vod/_definst_]: Publish: AllowedEncoders: securityPublishValidEncoders:Wirecast/|FME/|FMLE/|Wowza GoCoder\*|Lavf/|UA Teradek/|KulaByte/|VidBlaster/|XSplit/|PESA - - - 16846.885 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:34:56 IST comment server INFO 200 - ModuleCoreSecurity.onAppStart[vod/_definst_]: Publish: block duplicate stream names : false - - - 16846.885 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:34:56 IST comment server INFO 200 - ModuleCoreSecurity.onAppStart[vod/_definst_]: Play: SecureConnection: securityPlayRequireSecureConnection:false - - - 16846.885 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:34:56 IST comment server INFO 200 - ModuleCoreSecurity.onAppStart[vod/_definst_]: Play: securitySecureTokenVersion property is missing, using SecureToken Version 1, play security enabled for RTMP only - - - 16846.885 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:34:56 IST app-start application INFO 200 _definst_ vod/_definst_ - - - 16846.887 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:34:56 IST connect cupertino INFO 200 1916550908 - _defaultVHost_ vod _definst_ 0.023 192.168.7.10 1935 [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) 192.168.7.10 http (cupertino) [http://localhost:9006/multibitrate/dynamic](http://localhost:9006/multibitrate/dynamic) Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 Safari/537.36 1916550908 0 0 - 0 - - bigbuckbunny - - - - - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) -

2016-08-09 20:34:56 IST create stream INFO 200 bigbuckbunny - _defaultVHost_ vod _definst_ 0.001 192.168.7.10 1935 [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) 192.168.7.10 http (cupertino) [http://localhost:9006/multibitrate/dynamic](http://localhost:9006/multibitrate/dynamic) Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 Safari/537.36 1916550908 0 0 1 0 0 0 bigbuckbunny - - - - - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) -

2016-08-09 20:34:56 IST comment server WARN 200 - HTTPStreamerCupertinoIndexPlaylist.indexFile[vod/_definst_/amlst:bigbuckbunny]: MediaList is empty. - - - 0.024 - - - - - - - - - - - - - - - - - - - - - - - - -

2016-08-09 20:35:30 IST destroy stream INFO 200 bigbuckbunny - _defaultVHost_ vod _definst_ 34.043 192.168.7.10 1935 [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) 192.168.7.10 http (cupertino) [http://localhost:9006/multibitrate/dynamic](http://localhost:9006/multibitrate/dynamic) Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 Safari/537.36 1916550908 0 531 1 0 0 0 bigbuckbunny - - - - - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) -

2016-08-09 20:35:30 IST disconnect cupertino INFO 200 1916550908 - _defaultVHost_ vod _definst_ 34.067 192.168.7.10 1935 [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) 192.168.7.10 http (cupertino) [http://localhost:9006/multibitrate/dynamic](http://localhost:9006/multibitrate/dynamic) Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 Safari/537.36 1916550908 0 531 - 0 - - bigbuckbunny - - - - - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) - [http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8](http://192.168.7.10:1935/vod/amlst:bigbuckbunny/playlist.m3u8) -

I have check path : My ModuleAMLSTTest is located under com.jagir.wowza.smil package

---

<div class="post-metadata">

**Author:** ![Jagir\_Highq](https://avatars.discourse-cdn.com/v4/letter/j/c37758/32.png) [@Jagir\_Highq](https://community.wowza.com/u/Jagir_Highq)\
**Post date:** [August 9, 2016, 11:09pm UTC](https://community.wowza.com/t/dynamic-smil-not-working/47330/6 "2016-08-09T23:09:55Z")

</div>

Thanks Salvdore.

After copy jar file to [install-dir]/lib folder , it’s working fine as expected.

Regards,

Jagir
