Archived from the Transloadit support forum. Originally posted on November 4, 2010; details may be outdated, see our docs for current behavior. Original thread
Ultimately, I would like to upload 4 sizes on S3: Original + 3 resize, I would like to avoid multiple http requests (1 for the original to S3, and 3 resizes to transloadit).
- Is there an assembly rule that would allow me to transfer the original size to S3 directly, without resize?
- If yes, would the size of the file be charged (since I don’t use your robots here)?
Actually, I found a way to do it, but it does not work, could you tell me what is wrong with this assembly?
{
auth:{key:"..."}
, steps:
{ thumb1:
{ robot: "\/image\/resize"
, width: 320
}
, thumb2:
{ robot: "\/image\/resize"
, width: 160
}
, store:
{ use: [":original", "thumb1", "thumb2"]
, robot: "/s3/store"
, bucket: "PhotoSafari"
, key: "..."
, secret: "..."
}
}
, redirect_url:“http:\/\/localhost:3000/uploading” , notify:“http:\/\/localhost:3000/uploaded” }
Hey Stan,
the code you pasted should work, but I think the JSON you posted here isn’t identical to what reached us. In your last assemblies I see this:
"use": {
"0": "thumb1",
"1": "thumb2"
},
That’s probably a problem with the way you encode your JSON.
Anyway, another thing I noticed is that you should set 'use': ':original' for your thumb2 step, otherwise it will have to wait for thumb1 to finish and use that file instead of executing in parallel.
Let me know if that helps!