Reputation: 628
I got started using Azure Media Services for a proof of concept that I am doing for a streaming solution. Things are going great in the sense that I am using SDK's to create channels and starting and stopping these channels. I am now in the phase of actually testing the streaming functionality where some problem came into play.
What I need to achieve is sort of a Live event with video on demand afterwards solution through the SDK's in the sense that:
Before actually worrying about creating the live event and starting the stream through the SDK's, I wanted to test the streaming using the channel which I created and started via the SDK's. I managed to create the channel using the SDK's with the following options:
{
"aad_tenant_domain": "my_tenant_id",
"rest_api_endpoint": "my_rest_api_endpoint_url",
"storage_key": "my_storage_key",
"app_client_id": "app_client_id",
"app_client_secret": "app_client_secret",
"live_stream_channel_name": "TestChannel",
"live_stream_channel_description": "Test Channel Live Stream",
"live_stream_encoding_type": "None",
"live_stream_streaming_protocol": "RTMP",
"live_stream_start_channel": false
}
I then started the channel manually in the portal, and created a default live event by clicking the "Go-Live" button in the portal. I managed to use Wirecast to stream video and I could view the live stream in the preview player in the portal as well as using the preview url in the Azure Media Player at http://ampdemo.azureedge.net/azuremediaplayer.html
I then stopped the stream in WireCast 3 minutes later, as well as the channel. Under the Live Events section in the channel I can still see the default live event that was created and when I open it, I can see a streaming locator url with a red exclamation mark next to it. It has been published but when I use this locator in the Azure media player, I get the following error:
A network error caused the video download to fail part-way
The play button on the live event is also greyed out.
I can see the asset in the assets list with 6 files which of one is a video/mp4 file of around 50MB.
Am I missing some important step such as having to encode the video during streaming instead of specifying none for encoding type when creating the channel? Could this be the reason why I cannot view my video on demand after the live stream has ended?
Upvotes: 1
Views: 485
Reputation: 628
Turns out it was the encoding settings. By following the below article and replicating all the settings, all functionality worked as expected. I could also access the video on demand even after the channel was stopped which is exactly what I wanted.
Upvotes: 0