Не могу установить заводские настройки для бэкэнда rocksdb!
public class RocksDBOptionsFactory extends DefaultConfigurableOptionsFactory {
@Override
public ColumnFamilyOptions createColumnOptions(ColumnFamilyOptions currentOptions) {
return super.createColumnOptions(currentOptions)
.setCompactionStyle(CompactionStyle.FIFO)
.setCompactionOptionsFIFO(
new CompactionOptionsFIFO()
.setMaxTableFilesSize(500 * (10 ^ 6))
);
}
}
try {
RocksDBStateBackend backend = new RocksDBStateBackend(STATE_CHECKPOINTS_DIR, STATE_BACKEND_INCREMENTAL);
backend.setOptions(new RocksDBOptionsFactory());
backend.enableTtlCompactionFilter();
env.setStateBackend(backend);
} catch (IOException e) {
e.printStackTrace();
}
Caused by: java.lang.LinkageError: loader constraint violation: loader (instance of org/apache/flink/util/ChildFirstClassLoader) previously initiated loading for a different type with name "org/rocksdb/ColumnFamilyOptions"