Refactored Aws S3 multipart upload handling