final Map<Integer, Exception> errorMap = Maps.newHashMap();
AtomicInteger errors = new AtomicInteger(0);
int maxRetries = Math.max(minRetries, parts * maxPercentRetries / 100);
int effectiveParts = remaining > 0 ? parts + 1 : parts;
try {
uploadId = client.initiateMultipartUpload(container,
ObjectMetadataBuilder.create().key(key).build()); // TODO md5
logger.debug(String.format("initiated multipart upload of %s to container %s" +
" with uploadId %s consisting from %s part (possible max. retries: %d)",
key, container, uploadId, effectiveParts, maxRetries));
// we need a bounded-blocking queue to control the amount of parallel jobs