[GitHub] [flink] zoltar9264 commented on a diff in pull request #22458: [FLINK-31743][statebackend/rocksdb] disable rocksdb log relocating wh…
zoltar9264 commented on code in PR #22458: URL: https://github.com/apache/flink/pull/22458#discussion_r1188033528 ## flink-state-backends/flink-statebackend-rocksdb/src/main/java/org/apache/flink/contrib/streaming/state/RocksDBResourceContainer.java: ## @@ -82,34 +88,42 @@ public final class RocksDBResourceContainer implements AutoCloseable { @VisibleForTesting public RocksDBResourceContainer() { -this(new Configuration(), PredefinedOptions.DEFAULT, null, null, false); +this(new Configuration(), PredefinedOptions.DEFAULT, null, null, null, false); } @VisibleForTesting public RocksDBResourceContainer( PredefinedOptions predefinedOptions, @Nullable RocksDBOptionsFactory optionsFactory) { -this(new Configuration(), predefinedOptions, optionsFactory, null, false); +this(new Configuration(), predefinedOptions, optionsFactory, null, null, false); } @VisibleForTesting public RocksDBResourceContainer( PredefinedOptions predefinedOptions, @Nullable RocksDBOptionsFactory optionsFactory, @Nullable OpaqueMemoryResource sharedResources) { -this(new Configuration(), predefinedOptions, optionsFactory, sharedResources, false); +this(new Configuration(), predefinedOptions, optionsFactory, sharedResources, null, false); } public RocksDBResourceContainer( Review Comment: Thanks for your explanation @Myasuka , I submit this [pr](https://github.com/apache/flink/pull/22545) do this, PTAL. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
[GitHub] [flink] zoltar9264 commented on a diff in pull request #22458: [FLINK-31743][statebackend/rocksdb] disable rocksdb log relocating wh…
zoltar9264 commented on code in PR #22458: URL: https://github.com/apache/flink/pull/22458#discussion_r1184659873 ## flink-state-backends/flink-statebackend-rocksdb/src/main/java/org/apache/flink/contrib/streaming/state/RocksDBResourceContainer.java: ## @@ -114,14 +117,18 @@ public RocksDBResourceContainer( this.handlesToClose = new ArrayList<>(); } -/** Gets the RocksDB {@link DBOptions} to be used for RocksDB instances. */ public DBOptions getDbOptions() { +return getDbOptions(null); +} + +/** Gets the RocksDB {@link DBOptions} to be used for RocksDB instances. */ +public DBOptions getDbOptions(File instanceRocksDBPath) { Review Comment: Thinks for your suggestion @Myasuka . -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
[GitHub] [flink] zoltar9264 commented on a diff in pull request #22458: [FLINK-31743][statebackend/rocksdb] disable rocksdb log relocating wh…
zoltar9264 commented on code in PR #22458: URL: https://github.com/apache/flink/pull/22458#discussion_r1176280348 ## flink-state-backends/flink-statebackend-rocksdb/src/main/java/org/apache/flink/contrib/streaming/state/RocksDBResourceContainer.java: ## @@ -59,6 +59,9 @@ public final class RocksDBResourceContainer implements AutoCloseable { private static final Logger LOG = LoggerFactory.getLogger(RocksDBResourceContainer.class); +// the filename length limit is 255 on most operating systems +private static final int INSTANCE_PATH_LENGTH_LIMIT = 255 - "_LOG".length(); Review Comment: Because when log dir is set, rocksdb will add the suffix '_LOG' to the instance path as the log file name, you can check it in https://github.com/ververica/frocksdb/blob/FRocksDB-6.20.3/file/filename.cc#L31 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org