3

I have a rails app that should allow users to upload videos and stream them. I'm using carrierwave-direct to upload the video files. Carrierwave-direct utilizes fog to upload directly to an Amazon S3 bucket. I kick off a background job for the upload using Sidekiq. This all works.

I now need to transcode each video as it is uploaded. I plan on using Amazon's Elastic Transcoder to do this. How do I kick off the transcoder with Sidekiq? After the file is uploaded, how do I use the AWS-SDK gem with Sidekiq to start a transcoding job and have a file from s3 be converted? Will I need a new background worker for this job? Can I just use only one worker for this? I'm lost on this issue. I have looked everywhere and the documentation on actually using the elastic transcoder is thin.

I'm looking for a more general answer and a sample just so that I can get started. Once I know how to handle this process I think that I can manage.

John Rotenstein
  • 241,921
  • 22
  • 380
  • 470
T. Cole
  • 191
  • 13
  • I answered a similar question, without Sidekiq. To add Sidekiq to this tutorial just queue the job with Sidekiq instead of posting it, and have Sidekiq post the job to the pipeline whenever you want it to: Using CarrierWave with Amazon Elastic Transcoder in a Rails app http://stackoverflow.com/a/36614492/3167238 – hephalump Apr 27 '16 at 04:47

1 Answers1

0

I think you need sidekick only to manage your own jobs. Elastisc Transcoder (ETS) is a job worker, only that you need is know when ETS has finished to converting your video. I'm trying to kick-off a way to do that, and update my file in the resource to get the url for the converted video.