Closed bensu closed 9 years ago
You're on a roll! :+1:
If you have an example it'd be great if you could add it to the changelog (just use "unreleased" or something like that as heading.)
Also are there any other changes to the Readme required to be in sync with the new message format for the uploaded
chan?
Forgot to document! While adding the changes to the README I produced a conflict. After solving it I can't push it into this branch, so I'm opening a new PR with the non-conflict changes in #7
Users can now provide a
:key-fn
to the server handler which givenfile-name
andmime-type
will determine the key to use for the S3 file.Caveat: if the client provides a file
my-file.txt
and the:key-fn
generates a random number as a key (i.e.12314345
), the file location in S3 is given by12314345
, which is what was passed back in thes3-pipe
uploaded channel. The file location is no longer sufficient for the client to know which file was successfully uploaded (in case of parallel uploads).My (non-backwards-compatible) proposal is to put in the
uploaded
channel all information relevant to the client: both the file object that was uploaded and the response from S3 which contains the:key
,:location
,:bucket
, and:etag
.