Class SegmentCopy.Builder
- java.lang.Object
-
- org.apache.jackrabbit.oak.segment.azure.tool.SegmentCopy.Builder
-
- Enclosing class:
- SegmentCopy
public static class SegmentCopy.Builder extends java.lang.Object
Collect options for theSegmentCopy
command.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SegmentCopy
build()
Create an executable version of theCheck
command.SegmentCopy.Builder
withAppendMode(java.lang.Boolean appendMode)
If enabled, existing segments will be skipped instead of overwritten in the copy process.SegmentCopy.Builder
withDestination(java.lang.String destination)
The destination path/URI to an existing segment store.SegmentCopy.Builder
withDestPersistence(SegmentNodeStorePersistence destPersistence)
The destinationSegmentNodeStorePersistence
.SegmentCopy.Builder
withErrWriter(java.io.PrintWriter errWriter)
The text error stream writer used to print erroneous output.SegmentCopy.Builder
withFlat(java.lang.Boolean flat)
If enabled, the segments hierarchy will be copied without any TAR archive being created, in a flat hierarchy.SegmentCopy.Builder
withMaxSizeGb(java.lang.Integer maxSizeGb)
Parameter for configuring the maximum size of the segment store transferSegmentCopy.Builder
withOutWriter(java.io.PrintWriter outWriter)
The text output stream writer used to print normal output.SegmentCopy.Builder
withRevisionsCount(java.lang.Integer revisionsCount)
The lastrevisionsCount
revisions to be copied.SegmentCopy.Builder
withSource(java.lang.String source)
The source path/URI to an existing segment store.SegmentCopy.Builder
withSrcPersistencee(SegmentNodeStorePersistence srcPersistence)
The destinationSegmentNodeStorePersistence
.
-
-
-
Method Detail
-
withSource
public SegmentCopy.Builder withSource(java.lang.String source)
The source path/URI to an existing segment store. This parameter is required.- Parameters:
source
- the source path/URI to an existing segment store.- Returns:
- this builder.
-
withDestination
public SegmentCopy.Builder withDestination(java.lang.String destination)
The destination path/URI to an existing segment store. This parameter is required.- Parameters:
destination
- the destination path/URI to an existing segment store.- Returns:
- this builder.
-
withSrcPersistencee
public SegmentCopy.Builder withSrcPersistencee(SegmentNodeStorePersistence srcPersistence)
The destinationSegmentNodeStorePersistence
.- Parameters:
srcPersistence
- the destinationSegmentNodeStorePersistence
.- Returns:
- this builder.
-
withDestPersistence
public SegmentCopy.Builder withDestPersistence(SegmentNodeStorePersistence destPersistence)
The destinationSegmentNodeStorePersistence
.- Parameters:
destPersistence
- the destinationSegmentNodeStorePersistence
.- Returns:
- this builder.
-
withOutWriter
public SegmentCopy.Builder withOutWriter(java.io.PrintWriter outWriter)
The text output stream writer used to print normal output.- Parameters:
outWriter
- the output writer.- Returns:
- this builder.
-
withErrWriter
public SegmentCopy.Builder withErrWriter(java.io.PrintWriter errWriter)
The text error stream writer used to print erroneous output.- Parameters:
errWriter
- the error writer.- Returns:
- this builder.
-
withRevisionsCount
public SegmentCopy.Builder withRevisionsCount(java.lang.Integer revisionsCount)
The lastrevisionsCount
revisions to be copied. This parameter is not required and defaults to1
.- Parameters:
revisionsCount
- number of revisions to copied.- Returns:
- this builder.
-
withFlat
public SegmentCopy.Builder withFlat(java.lang.Boolean flat)
If enabled, the segments hierarchy will be copied without any TAR archive being created, in a flat hierarchy.- Parameters:
flat
- flag controlling the copying in flat hierarchy.- Returns:
- this builder.
-
withAppendMode
public SegmentCopy.Builder withAppendMode(java.lang.Boolean appendMode)
If enabled, existing segments will be skipped instead of overwritten in the copy process.- Parameters:
appendMode
- flag controlling the segment write behavior.- Returns:
- this builder.
-
withMaxSizeGb
public SegmentCopy.Builder withMaxSizeGb(java.lang.Integer maxSizeGb)
Parameter for configuring the maximum size of the segment store transfer- Parameters:
maxSizeGb
- the maximum size up to which repository data will be copied- Returns:
- this builder.
-
build
public SegmentCopy build()
Create an executable version of theCheck
command.- Returns:
- an instance of
Runnable
.
-
-