Modifier and Type | Method and Description |
---|---|
Compact |
build()
Create an executable version of the
Compact command. |
Compact.Builder |
withForce(boolean force)
Whether to fail if run on an older version of the store of force
upgrading its format.
|
Compact.Builder |
withGCLogInterval(long gcLogInterval)
The number of nodes after which an update about the compaction
process is logged.
|
Compact.Builder |
withMmap(@Nullable Boolean mmap)
Whether to use memory mapped access or file access.
|
Compact.Builder |
withOs(String os)
Which operating system the code is running on.
|
Compact.Builder |
withPath(File path)
The path to an existing segment store.
|
Compact.Builder |
withSegmentCacheSize(int segmentCacheSize)
The size of the segment cache in MB.
|
public Compact.Builder withPath(File path)
path
- the path to an existing segment store.public Compact.Builder withMmap(@Nullable @Nullable Boolean mmap)
mmap
- true
for memory mapped access, false
for
file access null
to determine the access mode
from the system architecture: memory mapped on 64 bit
systems, file access on 32 bit systems.public Compact.Builder withOs(String os)
os
- The operating system as returned by the "os.name" standard
system property.public Compact.Builder withForce(boolean force)
force
- upgrade iff true
public Compact.Builder withSegmentCacheSize(int segmentCacheSize)
SegmentCache.DEFAULT_SEGMENT_CACHE_MB
when this method is not
invoked.segmentCacheSize
- cache size in MBIllegalArgumentException
- if segmentCacheSize
is not a
positive integer.public Compact.Builder withGCLogInterval(long gcLogInterval)
gcLogInterval
- The log interval.Copyright © 2012–2020 The Apache Software Foundation. All rights reserved.