I have to deal with a directory of about 2 million xml\'s to be processed.
I\'ve already solved the processing distributing the work between machines and threads us
You can do that with Apache FileUtils library. No memory problem. I did check with visualvm.
Iterator it = FileUtils.iterateFiles(folder, null, true); while (it.hasNext()) { File fileEntry = (File) it.next(); }
Hope that helps. bye