tags:

views:

3053

answers:

4

My ASP.NET MVC application will take a lot of bandwidth and storage space. How can I setup an ASP.NET upload page so the file the user uploaded will go straight to Amazon S3 without using my web server's storage and bandwidth?

+8  A: 

You can write a form that posts directly to Amazon's S3 service via HTML POST. That should prevent you from needing the bandwidth on your end, assuming you need to do no processing of the content yourself before sending it to S3.

Jonathan
Nice!!! It's hard to find some of those Amazon samples and this was one I definitely could have used awhile ago. Thank you.
PhantomTypist
+2  A: 

ThreeSharp is a library to facilitate interactions with Amazon S3 in a .NET environment.

You'll still need to host the logic to upload and send files to s3 in your mvc app, but you won't need to persist them on your server.

Kyle Chafin
ThreeSharp is stoping thier project due to Amazon's efforts. This is from thier site: "We recommend developers migrate to the AWS SDK at their earliest convenience, as we will no longer be maintaining the ThreeSharp library. "
Stradas
+1  A: 

Look for a javascript library to handle the client side upload of these files. I stumbled upon a javascript and php example Dojo also seems to offer a clientside s3 file upload.

Aaron Fischer
+3  A: 

If you need to upload large files and display a progress bar you should consider the flajaxian component.

It uses flash to upload files directly to amazon s3, saving your bandwidth.

holiveira