public enum PredefinedOptions extends Enum<PredefinedOptions>
PredefinedOptions
are configuration settings for the RocksDBStateBackend
.
The various pre-defined choices are configurations that have been empirically
determined to be beneficial for performance under different settings.
Some of these settings are based on experiments by the Flink community, some follow guides from the RocksDB project.
Enum Constant and Description |
---|
DEFAULT
Default options for all settings, except that writes are not forced to the
disk.
|
FLASH_SSD_OPTIMIZED
Pre-defined options for Flash SSDs.
|
SPINNING_DISK_OPTIMIZED
Pre-defined options for regular spinning hard disks.
|
SPINNING_DISK_OPTIMIZED_HIGH_MEM
Pre-defined options for better performance on regular spinning hard disks,
at the cost of a higher memory consumption.
|
Modifier and Type | Method and Description |
---|---|
abstract org.rocksdb.ColumnFamilyOptions |
createColumnOptions()
Creates the
ColumnFamilyOptions for this pre-defined setting. |
abstract org.rocksdb.DBOptions |
createDBOptions()
Creates the
DBOptions for this pre-defined setting. |
static PredefinedOptions |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static PredefinedOptions[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PredefinedOptions DEFAULT
Note: Because Flink does not rely on RocksDB data on disk for recovery, there is no need to sync data to stable storage.
public static final PredefinedOptions SPINNING_DISK_OPTIMIZED
This constant configures RocksDB with some options that lead empirically to better performance when the machines executing the system use regular spinning hard disks.
The following options are set:
Note: Because Flink does not rely on RocksDB data on disk for recovery, there is no need to sync data to stable storage.
public static final PredefinedOptions SPINNING_DISK_OPTIMIZED_HIGH_MEM
NOTE: These settings will cause RocksDB to consume a lot of memory for
block caching and compactions. If you experience out-of-memory problems related to,
RocksDB, consider switching back to SPINNING_DISK_OPTIMIZED
.
The following options are set:
Note: Because Flink does not rely on RocksDB data on disk for recovery, there is no need to sync data to stable storage.
public static final PredefinedOptions FLASH_SSD_OPTIMIZED
This constant configures RocksDB with some options that lead empirically to better performance when the machines executing the system use SSDs.
The following options are set:
Note: Because Flink does not rely on RocksDB data on disk for recovery, there is no need to sync data to stable storage.
public static PredefinedOptions[] values()
for (PredefinedOptions c : PredefinedOptions.values()) System.out.println(c);
public static PredefinedOptions valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic abstract org.rocksdb.DBOptions createDBOptions()
DBOptions
for this pre-defined setting.public abstract org.rocksdb.ColumnFamilyOptions createColumnOptions()
ColumnFamilyOptions
for this pre-defined setting.Copyright © 2014–2020 The Apache Software Foundation. All rights reserved.