I have a very large file to import data into MongoDB via Javascript. The problem is that I can not load the entire file into memory.
I would like to read this file line by line, since each line is a record to insert into my bank. I know the fs library also works with stream, but it only looks for predefined byte sizes, without worrying if the line is gone or not. Has anyone done this?