|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.jgit.storage.dht.DhtInserterOptions
public class DhtInserterOptions
Options controlling how objects are inserted into a DHT stored repository.
Field Summary | |
---|---|
static int |
KiB
1024 (number of bytes in one kibibyte/kilobyte) |
static int |
MiB
1024 KiB (number of bytes in one mebibyte/megabyte) |
Constructor Summary | |
---|---|
DhtInserterOptions()
Create a default inserter configuration. |
Method Summary | |
---|---|
DhtInserterOptions |
fromConfig(Config rc)
Update properties by setting fields from the configuration. |
int |
getChunkSize()
|
int |
getCompression()
|
int |
getMaxObjectCount()
|
long |
getParserCacheLimit()
|
int |
getParserCacheSize()
Number of chunks the parser can cache for delta resolution support. |
int |
getPrefetchDepth()
Maximum number of entries in a chunk's prefetch list. |
int |
getWriteBufferSize()
|
DhtInserterOptions |
setChunkSize(int sizeInBytes)
Set the maximum size of a chunk, in bytes. |
DhtInserterOptions |
setCompression(int level)
Set the compression level used when writing new objects. |
DhtInserterOptions |
setParserCacheLimit(long limit)
Set the number of bytes the PackParser can cache. |
DhtInserterOptions |
setPrefetchDepth(int depth)
Maximum number of entries in a chunk's prefetch list. |
DhtInserterOptions |
setWriteBufferSize(int sizeInBytes)
Set the maximum number of outstanding bytes in a WriteBuffer . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int KiB
public static final int MiB
KiB
(number of bytes in one mebibyte/megabyte)
Constructor Detail |
---|
public DhtInserterOptions()
Method Detail |
---|
public int getChunkSize()
public DhtInserterOptions setChunkSize(int sizeInBytes)
sizeInBytes
- the maximum size. A chunk's data segment won't exceed this.
this
public int getWriteBufferSize()
public DhtInserterOptions setWriteBufferSize(int sizeInBytes)
WriteBuffer
.
sizeInBytes
- maximum number of bytes.
this
public int getMaxObjectCount()
public int getCompression()
public DhtInserterOptions setCompression(int level)
level
- the compression level. Use
Deflater.DEFAULT_COMPRESSION
to specify a default
compression setting.
this
public int getPrefetchDepth()
Each commit or tree chunk stores an optional prefetch list containing the next X chunk keys that a reader would need if they were traversing the project history. This implies that chunk prefetch lists are overlapping.
The depth at insertion time needs to be deep enough to allow readers to have sufficient parallel prefetch to keep themselves busy without waiting on sequential loads. If the depth is not sufficient, readers will stall while they sequentially look up the next chunk they need.
GitStore.ChunkMeta
list.public DhtInserterOptions setPrefetchDepth(int depth)
depth
- maximum depth of the prefetch list.
this
public int getParserCacheSize()
public long getParserCacheLimit()
public DhtInserterOptions setParserCacheLimit(long limit)
limit
- number of bytes the parser can cache.
this
public DhtInserterOptions fromConfig(Config rc)
If a property is not defined in the configuration, then it is left unmodified.
rc
- configuration to read properties from.
this
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |