Archive for ‘Developers’

July 23rd, 2014

What’s Next for HTML5 Video? Join our Talk at OSCON 2014

by Zohar Babin

Sharing the excitement from floor of OSCON 2014, Kaltura’s Director of Playback Experience and Video Monetization, Michael Dale talks about Kaltura, open source and his OSCON talk about what’s happening with web video standards and html5.
Be sure to visit Michael’s OSCON 2014 talk – HTML5 Video Part Deux; New Opportunities and New Challenges and come by our booth (#P1).

TF2A4144

June 27th, 2014

Test Driven Learning Begets Test Driven Development

by Michael 'Flip' McFadden

Slide1

Like most developers, I was approached by my management to “Make Something Work” without having any prior experience.  The job was to connect our Plone/Zope content management system to Kaltura, so web content editors could seamlessly upload and edit video content and metadata that is managed by the KMC.  It wasn’t hard to find the Kaltura Python API Client Library, but once you have the Client Library, you have to learn how to use it – and at the same time, learn the features that the KMC provides (see:
Kaltura Management Console Training Track).

I can read through the many docs from cover to cover (I usually don’t) and still have the uncomfortable, lost feeling of having no clue what’s going on. And then there’s always the pressure of overcoming the learning curve in a reasonable amount of time.
So I begin by writing “Playground Code”. A directory that will be filled with useless, proof-of-concept code that helps me get the hang of a language, an API, or a new concept. This code will never be used in production, which gives me the permission to write really bad code while I climb up the learning curve.
Being able to become unattached to code, throw it all away and start over, was an important step for me. You learn the ‘right way’ to do things by doing them the ‘wrong way’ first. It also helped me figure out where exactly I should be reading in the docs to get done what needs to be done.

In the past few years, I’ve been working a lot with the concept of Test-Driven-Development. In TDD you write very small, encapsulated tests before you actually code the functionality or patch you are implementing. You are, in fact, intentionally writing failing test cases. I found this method very useful for isolating and fixing bugs, but not so much for new large projects or new enhancement development. The requirement that the tests should be atomic and very specific does not lend itself to complicated projects with many moving parts. Until now.

When I found myself having to learn the Kaltura Python Client Library – having no prior experience, I found the concept of “Playground Code” and Test Driven Development coming together. I simply took my proof of concept, put together some code and threw an assert() statement at the end, and viola – it’s now a test case!

“How do I connect to a Kaltura Server with the Python API”

The answer was “testConnect()” - that was easily incorporated into a test suite using python’s excellent testing framework ‘unittest‘ (Then, assert that something like client.media.list() returns something that looks like a response. Or, at the very least, not an exception).
Viola: test_media.py

I developed the trivial, but important test case at the same time I learned how to connect to the Kaltura server! My code doesn’t have to be thrown away, nor does it have to be perfect. However, it can now serve the purpose of being a proof of concept, a unittest, and a code example for the next developer all at the same time.

When I got confused with something, I could easily take my entire test case, which was an atomic, very specific exercise/problem, and post it to the forums as is – and quickly get a direct answer on what was confusing me – instead of submitting a link to my entire application with the “xxxx not working” title, which would have made it harder for others to review and help.

And then it got even better. The proof of concept code grew as I learned more about the API. A large tests module started forming. I started coming finding small bugs in the Kaltura Python Client Library, nothing critical, but important to my application – And I was able to patch, test and contribute my code upstream to the Kaltura project.

Through my humble experience (from complete newbie state) with Kaltura’s API and Python Client Library, I was able to submit and contribute a more polished and complete Python Test suite for the Kaltura API Client Library!

@flipmcf

Want to join the Kaltura project and become an active contributor? Start Here.

June 4th, 2014

API Inside-Out – Tour of Kaltura’s API Driven Architecture

by Jess Portnoy

Being open source provides users of the Kaltura platform many advantages. Amongst which, the ability to shape and influence the platform and its roadmap by contributing code to the project.

More often, when building a new integration or a publishing workflow, it’s a bit too much to dive into the platform code. That’s why you don’t have to!

Kaltura is a RESTful API driven platform.
This means that all features, user facing or internal, are all based on the same unified API.
From upload to through transcoding to playback, is all controlled via the API.

A RESTful API follows the following concepts:

  • It’s uniform – in Kaltura, every service represents an object, and actions represents its methods . For example: the media service represents the KalturaMediaEntry object. The media.delete action deletes a given KalturaMediaEntry object.
  • It’s stateless – In every API call you must provide a valid session key (dubbed KS). You can also create as many sessions as you need at the same time.
  • It’s cacheable – Scale is a make or break with video applications. We cache more than 95% of API calls in Kaltura, once in memory and then even on the CDN.
  • Layered System – Client have a single end point. This encapsulates whether the client connect to the end server, or to an intermediary along the way. Intermediary servers improve system scalability by enabling load-balancing and shared caches. Layers also enforce security policies and enhance system resilience.

A lot of projects offer a RESTful API. But what I believe makes the Kaltura API special are -

It’s API from the inside out!
The platform’s own components also use the same APIs to get their job done. This means core developers build and test using the same APIs that App developers use. Which in turn test and improves the APIs daily.

Always up-to-date SDKs
Kaltura’s API features a unique automatic generation of SDK. With every release Kaltura generates new client libraries. Which are available in most popular programming languages, including: PHP, Ruby, Python and JavaScript.
See the Kaltura.com client libraries page for complete list and downloads.

It’s Robust, Allowing Complete Control
As an outcome, the API is capable of controlling pretty much any operation the platform’s core components. From ingesting content through management and transcoding, to playback, delivery, distribution and analytics.

To further explain point A, lets dive further in to the Kaltura architecture:

 

The API and Client Libraries, are used across the platform’s components, both in external applications such as Kaltura MediaSpace or various modules to 3rd party systems such as Drupal or WordPress, as well as internally, within core Kaltura components such as transcoding batch servers or the platform Admin Console.

For example, the batch daemon, responsible for performing roles such as: media import, media info extraction, transcoding and server notifications, triggers these APIs the same way any other party, for example, your application, would: using the Kaltura API Client libraries.

Here is a short example of how the APIs (in this particular case, the PHP client libs) can be used to upload a new video entry to the system:

Having an API driven architecture enables complete control and freedom with how you desire your application workflows and UI to be. From creating different publishing workflows to exposing sets of functionalities.
In addition, the API inside-out approach opens up many opportunities for adapting, controlling and extending beyond the simple UI workflows and apps, important examples are with platform automation and monitoring tools.

 

Playing with the API:

As mentioned, Kaltura provides client libs generated for various programming languages. In addition, API calls can be made using a testing tool dubbed the Kaltura TestMe console.
The first thing you would want to do is create a Kaltura Session – KS:

  1. Select ‘session’ as service and ‘start’ as action.
  2. In session type, select ‘USER’.
  3. The secret field corresponds to one of two strings that are saved in Kaltura for each partner and are available in your KMC under the Settings>Integration Settings tab. Note that there are two types of secrets, one that can be used to start an end-USER session and one to start an ADMIN session.

 

testme_session_start

If you look at the screen shot above, you will see that, in the right frame, we have the returned XML which includes:

  • The result tag with the KS ‘N2E1NGE1NGIxOGFlNWI3MDU1NWY4YTNmMTRjM2QwZDg2ZDA1YjM0MHwyNDk7MjQ5OzEzOTkyODc1OTA7MDsxMzk5MjAxMTkwLjM1NDs7Ozs=’ as value
  • The executionTime tag with 3.71932983398 as value

In the bottom of the page, you can see the code our selections in the input form generated.

Notice that while the default displayed code is in PHP, you can click on one of the other languages to see the code generated for any other.

 

Next for a second example using the Test Me Console, we will list the entries our partner owns. Doing so by using the baseEntry service and calling its listAction() function.

testme_baseentry_list

As you can see, the generated code reads:

If you run this code and add:

You will get a result very similar to the XML outputted in the right frame of the page in the screenshot above.

 

The Test Me Console is a useful method of starting to work with the Kaltura API. Simply browse through available services and see what actions can be made.

Then, you can copy the code snippet and shape it into something useful within your scripts.

 

Hopefully this article will help you get started with the Kaltura APIs.

Browse the Kaltura API Documentation Set to learn more and explore more Kaltura APIs.

For any questions, leave a comment below, or start a thread in the forums.

Download, install and take part in the Community.

 

Happy coding :)

Join us for the upcoming Video Experience Hackathon on June 13-5 in NYC. Polish your Kaltura API skills with the mentoring of experts and Kaltura core maintainers, and take a chance at winning the $50,000 prize!
The VideoX Hackathon, June 13-15, NYC

February 16th, 2014

Introducing KIPP – Kaltura Install Made Simple.

by Jess Portnoy

kaltura-light-blue-bg

The installation of Kaltura, just like the platform itself, went through a lot of metamorphosis over the years.

Over the years, we invested many resources at making Kaltura the best media management platform. Featuring grand batch system, complex metadata engine, robust entitlements, simplified video transcoding and more.

Alas, built on many different technologies, the installation of the platform became a bit of a complex task. Requiring many pre-install steps and several tricky pit-falls, even for the expert Linux engineers.

 

Announcing “KIPP” – Kaltura’s Install Packages Project!
Putting in place the resources to simplify and standardize the installation of Kaltura.
To enable the use of standard Linux package managers (e.g. yum, aptitude) to deploy the Kaltura platform with ease.

 

Community ahead!

It was important for us to create an open and collaborative project from day 1. Enabling community users to take part in defining, testing and developing the project.

Open repository and packaging tools -

All RPM and deb specs are accessible on an open GitHub repository.
Also available a chrooted ready-to-go build environment to allow experienced package developers to get started with ease and contribute packages for other CPU architectures or other operating systems.

 

Many dependancies, many challenges.
Kaltura requires many 3rd party components. Some of which are available via official Linux repositories. Many are in different versions or compilation options than what Kaltura requires. And other are missing altogether from official repositories.

Most packages are available from supplementary repositories such as EPEL and RPMForge. But, relying on unofficial repositories would force a list of pre-install steps that KIPP was set to avoid. And it would also introduce the challenge of keeping up with updates from these repositories.

 

Clean & Simple!
To meet our simplicity goal, we’ve chosen a few project guidelines.

All packages will have the ‘kaltura-’ prefix.
This ensures a no-conflict with other packages the machine may already have installed.
It would also provide a simple approach to handling updates -
# yum update "*kaltura*"

All files go under /opt/kaltura/.
Apart from standard init scripts: /etc/init.d and symlinks to Apache and logroate configurations. If the user runs the un-install script – everything gets removed.

Release notes matter.
Every package contains project metadata, that includes the project’s github repository and changes log. The changes-log contain all changes or patches for each version as well as links to Knowledge Center release notes.

Simple single-server without compromising cluster installs.
A single call to the ‘kaltura-server’ meta-package will install a complete all-in-one Kaltura server. But, as you grow your usage, so should your network grow into a smarter cluster of dedicated servers.

Modular packages structure.
A key characteristic of Kaltura is its ability to scale and deploy across any size cluster. The install packages should allow for the same level of modularity in deployment:

  1. You only install what you need.
  2. You should always know exactly what you have installed and of which version.
  3. You should have full control over which parts to update or patch.
  4. You should deploy packages based on desired server-role by calling its role. E.g. front, batch, sphinx, DB, etc.

Automated, silent installs.
Repurposing and adding new servers in your network should be a painless and automatic task.

Post-install script for each server role, allows for an easy deploy or repurpose of Kaltura servers.
Utilizing answers-file, preconfigured server-role templates allow for automatic deployment of new servers.
Admins can use Chef scripts with preconfigured answers-file to deploy complete clusters with ease.

Building for today, designing for long-term.
The short-term goal is to solve deployment of Kaltura on Fedora and Debian based Linux systems. Utilizing simple shell post-install scripts we maintain a common code base whenever possible. That allows for reuse in future packages, reducing time to package for other systems such BSD variants or even OSX.
Also, if we add new directives or variables in the future, all we need to update is the answer file template.

 

Support the project:

  • Kaltura Admins – Follow the new install guide (http://bit.ly/kipp-rpm). Help test the installation and upgrade flows.
  • Packagers / Package Developers – If you’re experienced with Linux packaging (or brew/macports on OSX) drop us a line!
  • Tech writers, translators and anyone who cares – Let’s reach everyone who cares about online video, anywhere!

To stay updated and learn more, visit the project page!

 

 

August 14th, 2013

Playing DRM Content in Native Applications (Video)

by Michael Dale

 

DRM (Digital Rights Management) is an important tool for premium and private content. The need for enforcing content license terms and for ensuring control over content monetization is of major concern when coming to provide an online media service that is available in an over-the-top / multi-platform environment. To help clients delivery to these multiple devices Kaltura has enhanced its native application developer tools ( SDKs ) for iOS and Android to support secured delivery.  

Significant attention and effort must be invested to make sure that content is protected for preventing unauthorized content distribution and enforcing corporate and educational viewing licenses.  

Kaltura provides multiple layers of content security: from a strictly secured infrastructure, through secured API sessions, a robust set of conditional access controls and multiple secured content delivery options. The addition of DRM technology to this security stack enables maximum protection of content by encrypting media assets, and by relying on a per-session license for playback. Playback is enabled only upon receiving this dedicated license which can be obtained only as part of a controlled environment through pre-defined rules.

Kaltura’s video platform is integrated today with Google Widevine’s DRM technology for content protection and with a near-term plan to enable a multi-DRM service as part of its video platform.

Playing DRM Content in Native Applications - Google Widevine

 

Kaltura’s integrated DRM service enables:

  1. Media Encryption as an integral part of the content ingestion process.
  2. License protected playback flow from multiple devices.
  3. Integrating with standard policy setting, license issuing flows and client-side protections provided by the DRM technology provider.
  4. Utilizing Kaltura’s Access Controls as an out-of-the-box authorization system integrated within the DRM license issuing flow.
  5. Enabling service-specific business logic for authorizing user/content entitlements as part of the DRM license issuing flow through Kaltura Access Control’s authorized session (KS) validation.
  6. Integrated Content Management – Encrypted content is seamlessly managed along-side with non-encrypted content from the same KMC account.

More details on Kaltura’s integrated service for DRM with Google Widevine are provided in this article on Kaltura’s Knowledge Center

In addition to the out-of-the-box support for DRM protected playback in PC environments using flash and the widevine extension, Kaltura recently introduced DRM support to its mobile reference applications and SDKs. These enhancements enable developers to secure content in the iOS and Android platforms. These tools have been integrated with the kaltura reference apps for easy integration into your native app projects. Here Eliza and Josh share how to get DRM up and running for iOS.

July 2nd, 2013

Will HTML5 Force Apple’s Hand Over Online Video Standards?

by Asef.Ahmed

Kaltura-Video-Platform-Device-Detection-and-SupportOur very own Michael Dale was featured in a Broadcast Engineering article about how HTML5 may end Apple’s hegemonic authority and force the company to adopt the same standards as everybody else.  The new standards that HTML5 is setting such as: adaptive streaming with MPEG-Dash and Media Stream API, content protection via Encrypted Media Extensions (EME), and the lack of a need for plugins, combined with the inevitable large rise in the number of HTML5 developers over the number of iOS developers, could significantly reduce Apple’s market power. As Dale puts it, ” Apple will continue to be one of the major targets for app and service development but it will no longer be setting the pace.”

Read the full article here:http://broadcastengineering.com/blog/html5-could-last-force-apple-fall-line-over-online-video-standards

May 20th, 2013

The Stanford University School of Medicine Kaltura Video Meetup and Hackathon – May 28, 10am to 4pm

by Zohar Babin

stanford-medical-kaltura-hackWe’re really excited to invite you to our first Kaltura Education hackathon – The Stanford University School of Medicine Kaltura Video Meet-up and Hackathon.

Join the Stanford University School of Medicine and Kaltura for exciting video application hacking, learn about Kaltura in Stanford School of Medicine, build cutting-edge video applications and a chance to win awesome prizes!

 

Venue: Stanford University (3160 Porter Drive, Palo Alto, CA 94304)
Time: Tuesday, May 28, 2013 from 10:00 AM to 4:00 PM (PDT)

Agenda:

10:00am – 10:30am
Meet and greet

10:30am – 11:15am
Presentation by the Web Services team of Stanford School of Medicine

  • Identifying and transferring our videos from Akamai to Kaltura
  • Analyzing our current environment and preparing for the migration
  • Updating our core video script to utilize the Kaltura Dynamic Player
  • Utilizing the Kaltura API to execute a mass update of our thumbnail images
  • Installing, customizing and configuring MediaSpace in the Stanford Medicine context

11:20am – 12:30pm
Presentation by Kaltura – The Kaltura API and “Video Expirements”

  • Building Kaltura API based Video Applications
  • Showcase of exciting education related video experiences
  • Sneak Peeks into the future of online video

12:30pm – 1:00pm
Lunch

1:00pm – 3:40pm
Hackathon: Building HTML5 Education Video Apps

3:40pm – 4pm
Hackathon Apps Showcase and Closing

 

 

Register to the event

 

 

April 26th, 2013

BlabDroid: The Personal Filmmaking Robot – An Interview with the Designer

by Iddo Shai

blabdroid-kickstarterWe have been following Alexander Reben and his robots since MIT’s Open Documentary Lab. After our previous blog post of Alex and his robots, we received a lot of great feedback which led us to visit Alex and talk to him about the future of human interaction. The idea is simple, can we emotionally connect to an extremely cute and adorable box? Apparently, the answer is yes and results in some pretty intense moments.

This week Alex and his gang of robots were busy at work – shooting all around Tribeca Festival. At the same time, Alex and his partner Brent Hoff launched a Kickstarter campaign to further develop the robots and bring them to the masses.

Join us in supporting Alex’s innovative project!

Watch below an exclusive interview with Alex and one of his innovative robots, about the history of the project, and hopes for its future.

Learn more about blabdroid at http://blabdroid.com/

March 13th, 2013

The New York HTML5 Hackfest Meetup Notes – March 2013

by Zohar Babin

Thank you for joining us last night at The NYC JavaScript & HTML5 Monthly Hackfest and for the amazing AlleyNYC for hosting us. We had a great fun (as always), and learned a lot.

For those who missed the meetup, here is a quick summary -

We’ve opened the evening with (pizza and drinks) Michael Dale, Player Framework Product Manager at Kaltura. Michael gave a presentation of the state of HTML5 video and writing a player framework, giving a walk-through of Kaltura’s HTML5 Player Framework and launching the evening into a hackfest of player plugins creation.

Following after, Costa Michailidis shared the beauty of SVG based web application design in a 5 minutes lightning talk about SGV. Judging by the exciting feedback this lightning talk received, we’ll have to followup with an in-depth SVG session in a future meetup!

We talked about HTML5 video, popcorn.js, mwEmbed, SVG and hacked on player plugins.

html5hackfest-alleynyc

March 7th, 2013

HTML5 Based Mobile OS and the Future of Video Phone Apps

by Gal Nachshon

FirefoxOS-logo_610x385 copyIt was nine years ago, during the W3C workshop in 2004, that Mozilla Foundation and Opera Software proposed, and has been rejected for, their desire to continue and develop HTML with a focus “on developing technologies that are backwards compatible with existing browsers.”

A few months later, unwilling to budge their admirable ambition, Mozilla, Opera, and Apple began working on the evolution of HTML “under the umbrella of a new venue called the WHATWG.” In 2007, after much work and development led by WHATWG, the W3C showed signs of interest and formed a working group chartered to work on the development of what came to be HTML5 specification. By the time HTML5 became the hottest trend in application development, mobile became the hottest trend in user consumption. Therefore, it was just a question of time that the two would marry. Especially since HTML5 offers new levels of innovation for mobile developers.

As of last month, February 2013, Firefox – the web browser from the house of Mozilla – has lunched its’ first HTML5-friendly mobile OS in Europe. The low cost, sub-$100, smart phone is now presenting a new challenge to Apples dominance over the smart firefox OSphone market. The new device, ZTE-made, is built on a open Web standards meaning “that every aspect of the device – including even the phone dialer – is built as an HTML5 application.”

Firefox claims that such an approach will allow faster performance than the HTML5 typically used on Android or iOS devices “where web apps have been often seen as inferior to native apps on those platforms.” Furthermore, Firefox OS “also gives carriers the chance to customize and localize those interfaces and services – including apps – as they choose, a level of flexibility they cannot have with iOS or Android.”

All of these rich features offered by Firefox OS are achieved through its flexible base of HTML5 and web applications, and like wise is Kaltura’s. As seen on the right, a Kaltura HTML5 player smoothly fits Firefox OS display screen without augmentation and faults. It is this bed of APIs upon which the Kaltura player is based on that provides a wide range service across all operating systems such as Firefox OS, but also iOS and Android SDK alike.

Kaltura’s HTML5 full featured player, however, is one of the fastest html5 players in its class, and as a recent study indicates, web viewers start dropping if a video does not start to play within 2 seconds or less. Hence, performance is key for retaining viewer engagement, but likewise is the design.

player-load-play-time

With Kaltura’s Dynamic Embed HTML5 player, a more flexible embed call allows for  changing run-time parameters easily, set up custom callbacks, and target a given DOM element in a page. The embed will inherit CSS classes and attributes of your DOM targets for robust Responsive Web Design support (sample page). This is critical since HTML5 is integrated into so many new form factors as with the Firefox OS phone.

The use of HTML5 enables the Kaltura player, as well as Firefox OS, to have a universal and flexible reach in today’s mobile world amongst many others whom picked up on the hot trends of HTML5 combined with mobile. Based on a recent global developer survey by Kendo UI, out of 5,000 developers, 36% preferred pure HTML5 implementation for all platforms, yet right behind them, at 32% of developers prefered hybrid apps that are developed in HTML5 code wrapped in a native container per target platform. This shift toward HTML5 is not surprising for not only does it give better end-user results, it also allows rapid development of apps.

For as a result of working per platform, instead of multi-platform via HTML5, 39% of developers spend time developing the same app/feature for multiple platforms instead of generating new ones. This workflow is time costly and impractical for the end user, who therefore has to wait long periods of time for upgrades on his mobile device OS and apps. Yet  HTML5, by developing apps across all platforms, generates a unison functionality with copious and flexible options to guarantee equivocal experience on any device and encourages effective future development.

We all appreciate the flexibility, robustness, and Mozilla’s ambitions to make HTML5 a first class citizen ever since 2004. However, until the day HTML5 will become a global standard, Kaltura still aims to support the best possible experiences in all environments such as iOS, Android, alongside HTML5. Therefore, Kaltura is also building native tools for experiences that can’t normally be delivered over html5 yet due to DRM, such as and adaptive streaming on Android, in order to achieve true universal reach today.