Hi, I am using Amazon S3 service to upload different directories (and the files inside) to different buckets (directory -> bucket). I am coding in Ruby, and I am using the lib http://amazon.rubyforge.org.
The files are small (about 20KB).
I'd like to upload the directories in parallel (using many threads) but I have to use synchronize around the S3Object.store
@mutex.synchronize do
S3Object.store(s3_obj_name, open(image_name), bucket_name)
end
If I don't use synchronize I obtain Net::HTTPBadResponse
exception !
So, with synchronize, I lost the advantages of using parallel programming.
Do you have some ideas about how to succeed in the parallel uploading ?
Thank you, Alessandro DS