jsedding commented on code in PR #2665:
URL: https://github.com/apache/jackrabbit-oak/pull/2665#discussion_r2630353256


##########
oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/AzureSegmentArchiveWriter.java:
##########
@@ -77,8 +79,10 @@ protected void doWriteArchiveEntry(RemoteSegmentArchiveEntry 
indexEntry, byte[]
         ioMonitor.beforeSegmentWrite(new File(blob.getBlobName()), msb, lsb, 
size);
         Stopwatch stopwatch = Stopwatch.createStarted();
         try {
-            blob.upload(BinaryData.fromBytes(Arrays.copyOfRange(data, offset, 
offset + size)), true);
-            blob.setMetadata(AzureBlobMetadata.toSegmentMetadata(indexEntry));
+            BinaryData binaryData = BinaryData.fromStream(new 
ByteArrayInputStream(data, offset, size), (long) size);

Review Comment:
   @joerghoh I added some performance numbers in the ticket. For a write-heavy 
use-case I measured an improvement of ~45%.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to