This is an automated email from the ASF dual-hosted git repository.

adulceanu pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/jackrabbit-oak.git


The following commit(s) were added to refs/heads/trunk by this push:
     new a2190a9846 OAK-10190 - Reusing Azure segment container hangs when 
primary location is not available (#898)
a2190a9846 is described below

commit a2190a9846bef418e2b3a3bfaf9c9af3f5dc9199
Author: Andrei Dulceanu <dulce...@users.noreply.github.com>
AuthorDate: Fri Apr 14 18:08:05 2023 +0300

    OAK-10190 - Reusing Azure segment container hangs when primary location is 
not available (#898)
---
 .../apache/jackrabbit/oak/segment/azure/AzureSegmentStoreService.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/AzureSegmentStoreService.java
 
b/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/AzureSegmentStoreService.java
index 9f515bda21..0ccf7fe475 100644
--- 
a/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/AzureSegmentStoreService.java
+++ 
b/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/AzureSegmentStoreService.java
@@ -134,8 +134,8 @@ public class AzureSegmentStoreService {
             cloudBlobClient.setDefaultRequestOptions(blobRequestOptions);
 
             CloudBlobContainer container = 
cloudBlobClient.getContainerReference(configuration.containerName());
-            if (createContainer) {
-                container.createIfNotExists();
+            if (createContainer && !container.exists()) {
+                container.create();
             }
             String path = normalizePath(configuration.rootPath());
             return new AzurePersistence(container.getDirectoryReference(path));

Reply via email to