FileServer.reserveFile has inconsistent behaviour when hasHeader is true. The first time the method is called for a given file and alias, it will throw IllegalArgumentException if the file cannot be opened. However subsequent invocations will return null. If the file exists but is empty, the method will always return null. The method ought to be consistent in its behaviour. It should either always return null, or always throw IllegalArgumentException. The advantage of throwing IllegalArgumentException is that the exception can be used to provide additional information on why the header is not available.
URL: http://svn.apache.org/r1659056 Log: FileServer.reserveFile - inconsistent behaviour when hasHeader is true Bugzilla Id: 57569 Modified: jmeter/trunk/src/core/org/apache/jmeter/services/FileServer.java jmeter/trunk/test/src/org/apache/jmeter/services/TestFileServer.java jmeter/trunk/xdocs/changes.xml URL: http://svn.apache.org/r1659057 Log: FileServer.reserveFile - inconsistent behaviour when hasHeader is true Bugzilla Id: 57569 Added: jmeter/trunk/bin/testfiles/empty.csv
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/3534