CDP:Direct Object Upload Pattern

From AWS-CloudDesignPattern
Jump to: navigation, search
Architect

Simplifying the Upload Procedure

Contents

Problem to Be Solved

Large data files from a large number of users are uploaded to photograph and video sharing sites. In some cases the upload process involves a high server-side load (particularly in terms of the network load), requiring a virtual server that is dedicated to uploads, even in sites that only are of a moderate scope.

Explanation of the Cloud Solution/Pattern

Leave the upload process to the Internet storage. That is, rather than having the upload from the client go through a virtual server, upload directly to the Internet storage. This lets you ignore the web server load caused by the upload process.

Implementation

  • Generate an HTML form, on the web server (the EC2 instance) for performing uploading to the Amazon Simple Storage Service (S3).
  • Use the upload form to upload the file directly from the user side to S3. Because there will be a redirect to the URL specified in the form after completion of transference of the file to S3, perform a process to confirm the completion of uploading on the server that is the destination of the redirect.

Configuration

2XNdewVsgellO3x8-99789.png

Benefits

  • There eliminates the labor or cost of preparing an EC2 instance for uploading.
  • This enables distribution of the load of the upload processes by taking advantage of the scalability of S3. The data is uploaded to S3, making it easy to share between EC2 instances.

Cautions

  • Because implementation must be performed in coordination with S3, this approach is complex when compared to uploading using an EC2 instance alone.

Other

  • See the following regarding a function for uploading to S3 using an HTML form: http://doc.s3.amazonaws.com/proposals/post.html
  • Because the HTML form can be created manually, both the distribution of the HTML form and the uploading can be performed using S3 alone.
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox