I’m creating a program that produce checksums for each files in directory. I’m using FileUtils.readFileToByteArray which internally creates a new FileInputStream. The problem is I didn’t find where the stream is closed and wondering about a possible memory leak. So I’m asking: does this method close the stream after reading it? Answer Short answer: yes, it closes the stream. Slightly
Tag: apache-commons-io
Apache Commons IO File Monitoring vs. JDK WatchService
I need to develop an application that will process csv files as soon as the files are created in a predefined directory. Huge number of incoming files is expected. I have seen applications using Apache Commons IO File Monitoring in the production. It works pretty well. I have seen it processing as many as 21 million files in a day.