New upload method to reduce memory usage

In my case I upload using InputStream and also know it's size/length. In
that case we can pass the length argument and be more efficient.
Imagine that the user want to upload an InputStream with a length
greater than 50MB. We would run out of memory by just copying it to a
byte array.