My favorites | Sign in
Project Logo
                
Search
for
Updated Nov 05, 2009 by api.jeffy
Labels: Featured
ArchitectureOverview  

YouTube Direct Architecture Overview

The YouTube Direct platform can be thought of as two related pieces, both running on Google App Engine's Java servers.

One piece is the backend administrative control panel. Google Account authentication ensures that only users explicitly provisioned as administrators will have access to this information. The administrative control panel consists of web pages written in JSP that use jQuery's ajax() method to request JSON data from administrative servlets. The servlets, in turn, request the relevant data from App Engine's datastore, filter the results, and return the appropriate JSON-formatted response. The administrative control panel also communicates with YouTube via the YouTube GData API to sync up each video's representation in the datastore with the current YouTube metadata, create YouTube playlists, and add approved videos to playlists.

The other piece of the YouTube Direct platform is the video submission "widget". This is comprised of a series of JSPs that are displayed in an iframe on a host website. The iframe approach allows the JSPs and video upload interaction to take place in code served by App Engine, without requiring any dynamic programming on the host website. The JSPs use AuthSub to request an authorization token that allows YouTube API upload calls to be made on behalf of a registered YouTube user. This authorization token is stored in the App Engine datastore, and a HTTP session id is persisted in a local browser cookie to match up stored AuthSub tokens with a given browser instance. If properly configured, the App Engine instance will email end users notifying them of their video submission's moderation status.

Architecture Diagram


Hosted by Google Code