I'm building an app that takes file uploads from a user and creates videos from them. I have the simplest-possible MVP runnign for it right now with a plain HTML form sending the contents to a serverless function on Zeit Now which returns a video URL.
Now I want user auth, proper database storage and start charging for it I'm building it out as a full Rails app.
My two options seem to be:
Upload the user files to the Rails app and do the video encoding in a background job then finally upload to S3 (shown in Episode #150 Shrine Backgrounding and Video Transcoding
Or I could use Active Storage to upload the source files direct to S3 and continue to use my Zeit Now serverless function to create the video via webhook calls.
Which would you choose and why? 🤔
I'm sticking with the external service for now. The biggest advantage is that it's already written and working.
Each video encode takes around 10 seconds and if I get a lot of users the server resources would need careful management in a Rails implementation. With the Zeit Now function it just scales automatically and can handle any number of encodes.
Join 27,623+ developers who get early access to new screencasts, articles, guides, updates, and more.