public File findFile(File directory, String fileName) throws ReaderException {
		if (count.poll() / 1000 > execution_time) {
			throw new ReaderException("Execution time was reached, exiting.");
		}
		
		// Get file in this directory ignore hidden directories/files (starting with '.')
		File[] dirFiles = directory.listFiles(new FilenameFilter() {
			public boolean accept(File dir, String name) {
				return !name.startsWith(".");
			}
		});
		
		if (dirFiles == null || dirFiles.length < 1) {
			return null;
		}
		
		// Loop files
		for (File file : dirFiles) {
			// Test if this is the configuration file
			if (file.getName().matches(fileName) && file.exists()) {
				return file;
			}
			
			if (file.isDirectory()) {
				File testDir = findFile(file, fileName);
				
				if (testDir != null) {
					return testDir;
				}
			}
		}
		
		return null;
	}