-
Notifications
You must be signed in to change notification settings - Fork 413
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
OAK-11267 - Upgrade Azure SDK V8 to V12 for oak-blob-azure
- Loading branch information
1 parent
1294f24
commit 2949118
Showing
25 changed files
with
2,571 additions
and
802 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
...org/apache/jackrabbit/oak/blob/cloud/azure/blobstorage/AbstractAzureBlobStoreBackend.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package org.apache.jackrabbit.oak.blob.cloud.azure.blobstorage; | ||
|
||
import org.apache.jackrabbit.core.data.DataIdentifier; | ||
import org.apache.jackrabbit.core.data.DataRecord; | ||
import org.apache.jackrabbit.core.data.DataStoreException; | ||
import org.apache.jackrabbit.oak.plugins.blob.datastore.directaccess.DataRecordDownloadOptions; | ||
import org.apache.jackrabbit.oak.plugins.blob.datastore.directaccess.DataRecordUpload; | ||
import org.apache.jackrabbit.oak.plugins.blob.datastore.directaccess.DataRecordUploadException; | ||
import org.apache.jackrabbit.oak.plugins.blob.datastore.directaccess.DataRecordUploadOptions; | ||
import org.apache.jackrabbit.oak.spi.blob.AbstractSharedBackend; | ||
import org.jetbrains.annotations.NotNull; | ||
|
||
import java.net.URI; | ||
import java.util.Properties; | ||
|
||
|
||
public abstract class AbstractAzureBlobStoreBackend extends AbstractSharedBackend { | ||
|
||
protected abstract DataRecordUpload initiateHttpUpload(long maxUploadSizeInBytes, int maxNumberOfURIs, @NotNull final DataRecordUploadOptions options); | ||
protected abstract DataRecord completeHttpUpload(@NotNull String uploadTokenStr) throws DataRecordUploadException, DataStoreException; | ||
protected abstract void setHttpDownloadURIExpirySeconds(int seconds); | ||
protected abstract void setHttpUploadURIExpirySeconds(int seconds); | ||
protected abstract void setHttpDownloadURICacheSize(int maxSize); | ||
protected abstract URI createHttpDownloadURI(@NotNull DataIdentifier identifier, @NotNull DataRecordDownloadOptions downloadOptions); | ||
public abstract void setProperties(final Properties properties); | ||
|
||
} |
234 changes: 69 additions & 165 deletions
234
...va/org/apache/jackrabbit/oak/blob/cloud/azure/blobstorage/AzureBlobContainerProvider.java
Large diffs are not rendered by default.
Oops, something went wrong.
695 changes: 284 additions & 411 deletions
695
...in/java/org/apache/jackrabbit/oak/blob/cloud/azure/blobstorage/AzureBlobStoreBackend.java
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
...azure/src/main/java/org/apache/jackrabbit/oak/blob/cloud/azure/blobstorage/Constants.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package org.apache.jackrabbit.oak.blob.cloud.azure.blobstorage; | ||
|
||
public interface Constants { | ||
String META_DIR_NAME = "META"; | ||
String META_KEY_PREFIX = META_DIR_NAME + "/"; | ||
|
||
String REF_KEY = "reference.key"; | ||
String LAST_MODIFIED_KEY = "lastModified"; | ||
|
||
long BUFFERED_STREAM_THRESHOLD = 1024 * 1024; | ||
long MIN_MULTIPART_UPLOAD_PART_SIZE = 1024 * 1024 * 10; // 10MB | ||
long MAX_MULTIPART_UPLOAD_PART_SIZE = 1024 * 1024 * 100; // 100MB | ||
long MAX_SINGLE_PUT_UPLOAD_SIZE = 1024 * 1024 * 256; // 256MB, Azure limit | ||
long MAX_BINARY_UPLOAD_SIZE = (long) Math.floor(1024L * 1024L * 1024L * 1024L * 4.75); // 4.75TB, Azure limit | ||
int MAX_ALLOWABLE_UPLOAD_URIS = 50000; // Azure limit | ||
int MAX_UNIQUE_RECORD_TRIES = 10; | ||
int DEFAULT_CONCURRENT_REQUEST_COUNT = 2; | ||
int MAX_CONCURRENT_REQUEST_COUNT = 50; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.