Re: [go-nuts] Reading data from a small number of files in parallel

2020-02-14 Thread Robert Engels
You cannot use a pool of File if rotated means close, rename , reopen. A File is a user space representation of an inode so rotating means the File still points to the original file (beware on Windows). A file open / reopen is really cheap on recent files in a modern os. If the real issue you

[go-nuts] Reading data from a small number of files in parallel

2020-02-14 Thread Ice man
Hi everyone, I am building a system where we store data (text) in a file for a day and at the end of the day the file is rotated. For each data, one single file contains the data for that file. I was wondering what would be the best way to read from the file, opening the file for reading each ti