You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-commits@jackrabbit.apache.org by ad...@apache.org on 2024/09/26 13:34:16 UTC
(jackrabbit-oak) branch trunk updated: OAK-11152 - Segment copy - avoid instantiation of source persistence if it is not null (#1743)
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 239854059e OAK-11152 - Segment copy - avoid instantiation of source persistence if it is not null (#1743)
239854059e is described below
commit 239854059e49d261db8d0a75112be0194fb18a65
Author: Andrei Dulceanu <du...@users.noreply.github.com>
AuthorDate: Thu Sep 26 15:34:10 2024 +0200
OAK-11152 - Segment copy - avoid instantiation of source persistence if it is not null (#1743)
---
.../org/apache/jackrabbit/oak/segment/azure/tool/SegmentCopy.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/tool/SegmentCopy.java b/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/tool/SegmentCopy.java
index 92fffcb101..d14d95084b 100644
--- a/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/tool/SegmentCopy.java
+++ b/oak-segment-azure/src/main/java/org/apache/jackrabbit/oak/segment/azure/tool/SegmentCopy.java
@@ -287,7 +287,9 @@ public class SegmentCopy {
if (flat && destType == SegmentStoreType.TAR) {
try {
- srcPersistence = newSegmentNodeStorePersistence(srcType, source, azureStorageCredentialManager);
+ if (srcPersistence == null) {
+ srcPersistence = newSegmentNodeStorePersistence(srcType, source, azureStorageCredentialManager);
+ }
SegmentArchiveManager sourceManager = srcPersistence.createArchiveManager(false, false,
new IOMonitorAdapter(), new FileStoreMonitorAdapter(), new RemoteStoreMonitorAdapter());