Getting Started with TransloadIt – Key Concepts

An excerpt from, by @lukaswhite

Transloadit is a file-processing service primarily designed for processing images, videos and audio.

It allows you to perform various operations — conducted by what it calls “robots” — on these files; for example resizing and optimizing images, extracting thumbnails from videos or converting files from one format to another.

TransloadIt also allows you to upload files directly to their servers for processing rather than via your application. Indeed you can bypass your server altogether, transferring the processed files straight to an Amazon S3 bucket, a Rackspace Cloud Files account or to your own server via (S)FTP. So in other words, your application need only be concerned with where to find the resulting files, without having to process or store them directly — great for running distributed applications or for those on clusters.

In this tutorial we’re going to take a detailed look at Transloadit, and in particular using it to handle images. We’ll look at some of the key concepts, such as constructing “assembly instructions” to tell it what we want to happen to our uploaded image files. We’ll “hijack” a file upload form to send a file directly to TransloadIt, run a set of instructions to generate a number of “derivatives” — different-sized images — and then save them to an Amazon S3 bucket. Finally, we’ll look at how we can use the results of these operations to notify our application about the newly generated files, so that we can update our database accordingly.

Before we look in detail at Transloadit, it’s worth taking a step back and discussing why you’d want to use a third-party service for something like this in the first place, rather than implement it all yourself.

Continue reading this article on SitePoint

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.