1

Sorry if duplicate but I couldn't find much on web. I am working on website platform for streaming and education. The website needs to handle big files ( mostly videos) and thumbnails. The website is hosted on Azure.

Would it be better to store the media files on azure blob storage or within the public folder inside web app?

I tried both and when I store them inside azure blob storage the videos are taking half a minute to load + you can't seek the video.

brpetrov
  • 119
  • 2
  • 11

1 Answers1

1

At present, your big video resource has not been processed and directly let Html play it, so during the loading process, you feel that it is very slow, it feels like it is downloading, but it is not. This is the loading of network transmission. You can check it with F12->Network, or use Fiddler to check.

I have two suggestions.

One is to use Azure Media Services

Using new Services, so that under the same region or resourcegroup, the loading speed should be significantly improved. Because AMS processed all the video uploads.

Advantages (compared with your existing method and the second method below):

  1. It can be played by adapting various stream.
  2. No need to process the video by yourself.

Disadvantages: You need to use new Services, you may need to learn (you only need to understand the video upload process, use the official player, and embed Html code in your php page, so the learning cycle will be very short, half a day. ), new services will be charged extra.

Another one is to process the video in the background encoding.

Two concepts are introduced: block and chunk

Large files() can be processed as needed. And you also can load chunks into html5 video.

It has nothing to do with where the files are stored. For large files, the loading speed is slow and there is little difference.

Related Articles or Posts

1. How to stream large .mp4 files?

2. Video.js download chunk instead of the whole video

Jason Pan
  • 15,263
  • 1
  • 14
  • 29
  • Thanks for clarifying that! I thought it's the storage place causing it as the videos worked OK when they were stored inside the public folder via symlink. Is that because they were cached? – brpetrov Feb 03 '21 at 09:24
  • Also, I am currently using plyr to get some data like (how many times the video was watched/completed). Do you think encoding/ azure media services might affect these event listeners? – brpetrov Feb 03 '21 at 09:25
  • @brpetrov You can use [Azure media play as a player](https://i.stack.imgur.com/6x8AN.png) without affecting your other functions. – Jason Pan Feb 03 '21 at 09:29
  • 1
    @brpetrov [Azure Media Player Source Code](https://amp.azure.net/libs/amp/latest/docs/samples.html), it just `div` tag. In addition, your problem should only exist in large files, and I believe your internet speed should be very good, otherwise the loading time will be longer. This slow loading is caused by the file being too large and also affected by the internet speed limit. – Jason Pan Feb 03 '21 at 09:33