I need to write objects, sent to me from another process, to several files on my disk. Each object comes with fileID (the name of file to be written in to) and chunks of data.
I would like to use IO completion port (IOCP) in order to optimize the files writing, using concurrent asynchronous I/O, but I have to write each file, synchronically, e.g. I have to keep the chunk order per-file when writing to disk but not files order.
I understand that .Net using IOCP whenever it does an IO operation but how do i make it work the way I want?