Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Image upload -> manipulation -> copy to S3
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  4 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
railsnerd  
View profile  
 More options Sep 27 2010, 9:43 pm
From: railsnerd <rails.n...@gmail.com>
Date: Mon, 27 Sep 2010 18:43:54 -0700 (PDT)
Local: Mon, Sep 27 2010 9:43 pm
Subject: Image upload -> manipulation -> copy to S3
Hi

First of all, I realise Heroku encourages us to upload directly to S3.

However I'd like to manage that upload via Heroku first.

Two questions:

1) With Heroku I understand your request can have some temporary space
for file uploads. Can I rely on that space to exist for a few minutes
while a Delayed Job gets to it?

2) Does uploading a file completely lock a dyno?  Or can a single dyno
handle a few simultaneous uploads?

cheers


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Oren Teich  
View profile  
 More options Sep 28 2010, 12:07 am
From: Oren Teich <o...@heroku.com>
Date: Mon, 27 Sep 2010 21:07:07 -0700
Local: Tues, Sep 28 2010 12:07 am
Subject: Re: Image upload -> manipulation -> copy to S3

> 1) With Heroku I understand your request can have some temporary space
> for file uploads. Can I rely on that space to exist for a few minutes
> while a Delayed Job gets to it?

The space is for the request.  A delayed job will run as a seperate
process, so no, you can't count on it being there.  Chances are high
that the delayed job will run on a different machine, and not have
access to the file.

Note that for small files, you can have the dyno upload to s3 as part
of the process.  Paperclip supports this out of the box.  I have sites
myself working this way.

> 2) Does uploading a file completely lock a dyno?  Or can a single dyno
> handle a few simultaneous uploads?

A dyno is by definition one simultaneous request.  That dyno is locked
for the duration of the upload.

Oren


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Idris  
View profile  
 More options Sep 28 2010, 2:12 pm
From: Idris <idr...@gmail.com>
Date: Tue, 28 Sep 2010 11:12:03 -0700 (PDT)
Local: Tues, Sep 28 2010 2:12 pm
Subject: Re: Image upload -> manipulation -> copy to S3
Why not just upload the file straight to S3 (I recommend not going
through paperclip, but instead going straight to S3, so you don't hold
up the dyno).  Then when the upload finishes, kick off a background
job to read the image off S3, process it, and save the processed
image.

On Sep 28, 12:07 am, Oren Teich <o...@heroku.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Cortens  
View profile  
 More options Sep 28 2010, 11:47 pm
From: Paul Cortens <p...@thoughtless.ca>
Date: Tue, 28 Sep 2010 20:47:18 -0700 (PDT)
Local: Tues, Sep 28 2010 11:47 pm
Subject: Re: Image upload -> manipulation -> copy to S3
On Sep 28, 11:12 am, Idris <idr...@gmail.com> wrote:

> Why not just upload the file straight to S3 (I recommend not going
> through paperclip, but instead going straight to S3, so you don't hold
> up the dyno).  Then when the upload finishes, kick off a background
> job to read the image off S3, process it, and save the processed
> image.

This is exactly what I'd recommend if you want something scalable.
There are a few flash-based plugins that will even let you upload
directly to S3 so your dyno is not tied up. I have used this to allow
users to upload videos.

That said, if you are just dealing with images, setting up direct-to-
s3 uploading (and all the callbacks and background processing
associated with it) can be way too much development time.
It won't scale, but for small-to-medium sites, using paperclip and
having the dyno resize your images then upload to S3 will work just
fine.

Paul


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »