Amazon S3 via C#
Amazon Simple Storage Service (Amazon S3) via C#
Amazon S3 is storage for the Internet. It is designed to make web-scale computing easier for developers. It’s provides a simple web services interface that can be used to store and retrieve any amount of data, at any time, from anywhere on the web.
It uses standards-based REST and SOAP interfaces so it is platform independent and language independent.
It `s commercial but highly scalable, reliable, fast and inexpensive data storage infrastructure.
To know more about its advantage and the cost click here:
http://www.amazon.com/gp/browse.html?node=16427261
I am writing here to give you my experiences and tricks which I faced it when I started in develop the service using Dot Net (C#) and soap.
First trick:
When you work using .Net, you must use WSE 2.0 NOT WSE 3.0 as Amazon support DIME (WSE 2.0) NOT MTOM (WSE 3.0).
Second trick:
You can only using the class System.Web.Services.Protocols.SoapHttpClientProtocol, if you want upload files to AWS (Amazon Web Service) that are less than one Megabytes.
Here is an excellent example that server the required (files less than megabyte) with complete demo code for view and upload files.
http://developer.amazonwebservices.com/connect/entry.jspa?externalID=774&categoryID=55
Third trick:
If your files are bigger than one Megabytes (ten, twenty or may be 50 megabytes), you must to change the class System.Web.Services.Protocols.SoapHttpClientProtocol to Microsoft.Web.Services2.WebServicesClientProtocol . (As mentioned in this link)
Then follow the last trick...
Last trick:
You must raise the Timeout property that inherits the Microsoft.Web.Services2.WebServicesClientProtocol (the AmazonS3class if you opened the following example) more time out (this property measures in milliseconds) .
Here it an excellent example that server the required (more than one megabyte) with complete code.
The Amazon S3 Developer Guide :