Git Product home page Git Product logo

wams-async-cors-upload's Introduction

WAMS async CORS enabled video upload demo

This is an ASP.NET MVC demo application created as a proof-of-concept on how to do async CORS enabled video upload to Azure Media Services. To create WAMS assets and locators and to run WAMS encoding job/tasks, a WebAPI service using WAMS .net SDK v3 was used. By doing all that stuff on the server, it's easier to keep everything secure since your Azure credentials are not public and you are the one in charge of creating all the assets, locators and jobs. WAMS REST API was used only to upload chunks of data directly to Azure. By uploading the data directly to Azure, both CPU load and bandwidth consumption of the server hosting the web application are lowered (just imagine a scenario where your web application is not hosted through Azure and all the blob data needs to go through it for each file upload).

Here is a blog post which explains the whole workflow of the application:
Building Windows Azure Media Services async CORS enabled upload

WAMS configuration

Your WAMS credentials need to be entered in web.config => appSettings ("azureAccountName", "azureAccountKey", "wamsAccountName" and "wamsAccountKey") for the application to work.

CORS rules setup

To set-up the CORS rules for your Azure account, you can use azure-cors-rule-manager. You will need to create a CORS rule with the following settings for WACU to work:

  • Allowed origins: http://yourdomain
  • Allowed methods: PUT
  • Allowed headers: content-type, accept, x-ms-*
  • Exposed headers: x-ms-*
  • Max age (seconds): 3600 (you can set a lower or higher value for this one)

Credits

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

Made at: Mono Software Ltd.

wams-async-cors-upload's People

Contributors

tihomir-kit avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.