tkalkirill commented on code in PR #6673:
URL: https://github.com/apache/ignite-3/pull/6673#discussion_r2394413899


##########
modules/file-io/src/main/java/org/apache/ignite/internal/fileio/AsyncFileIo.java:
##########
@@ -48,11 +49,12 @@ public class AsyncFileIo extends AbstractFileIo {
      * Creates I/O implementation for specified file.
      *
      * @param filePath File path.
+     * @param asyncIoExecutor Callback executor.
      * @param modes Open modes.
      * @throws IOException If some I/O error occurs.
      */
-    public AsyncFileIo(Path filePath, OpenOption... modes) throws IOException {
-        ch = AsynchronousFileChannel.open(filePath, modes);
+    public AsyncFileIo(Path filePath, ExecutorService asyncIoExecutor, 
OpenOption... modes) throws IOException {
+        ch = AsynchronousFileChannel.open(filePath, Set.of(modes), 
asyncIoExecutor);

Review Comment:
   Technically, the behavior changes. If you pass an empty array in the main, 
nothing will happen. 
   Your change will throw an exception. Let's not change the behavior and just 
add `modes.len == 0 ? Se.of() : Set.of(modes)`.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to