akka/akka-core

Use AsynchronousFileChannel for FileSource

Open

#30.031 geöffnet am 14. Feb. 2021

Auf GitHub ansehen
 (4 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Scala (3.547 Forks)batch import
1 - triagedhelp wantednice-to-have (low-prio)t:stream

Repository-Metriken

Stars
 (13.277 Stars)
PR-Merge-Metriken
 (Durchschn. Merge 17h 35m) (11 gemergte PRs in 30 T)

Beschreibung

I was a bit surprised reading the Streaming File IO docs to read

Please note that these operators are backed by Actors and by default are configured to run on a pre-configured threadpool-backed dispatcher dedicated for File IO. This is very important as it isolates the blocking file IO operations from the rest of the ActorSystem allowing each dispatcher to be utilised in the most efficient way.

Looking around I found that AsyncFileChannel was implemented differently on different Operating Systems. So on Windows apparently it does use underlying asynchronous IO.

It would be interesting to find out on which other platforms this makes a difference.

Contributor Guide