pub fn new_with_size<S>(stream: S, size_hint: usize) -> ByteStream
    where
        S: Stream<Item = Result<Bytes, io::Error>> + Send + 'static,
    {
        ByteStream {
            size_hint: Some(size_hint),
            inner: Box::pin(stream),
        }
    }
Creates a new `ByteStream` by wrapping a `futures` stream. Allows for the addition of a
size_hint to satisy S3's `PutObject` API.
rusoto/signature/src/stream.rs