Bug 59153

Summary: java.io.FileNotFoundException with a CSV Data Set Config + empty filemane field
Product: JMeter Reporter: Antonio Gomes Rodrigues <ra0077>
Component: MainAssignee: JMeter issues mailing list <issues>
Status: RESOLVED FIXED    
Severity: minor CC: ra0077
Priority: P2    
Version: Nightly (Please specify date)   
Target Milestone: ---   
Hardware: PC   
OS: Windows NT   
Attachments: Test plan to reproduce the bug

Description Antonio Gomes Rodrigues 2016-03-09 12:56:12 UTC
Created attachment 33653 [details]
Test plan to reproduce the bug

Hi,

Whe you add a CSV Data Set Config in your test plan and you don't fill the filename field we have an exception

ERROR - jmeter.threads.JMeterThread: Test failed! java.lang.IllegalArgumentException: Could not read file header line
	at org.apache.jmeter.services.FileServer.reserveFile(FileServer.java:280)
	at org.apache.jmeter.config.CSVDataSet.iterationStart(CSVDataSet.java:178)
	at org.apache.jmeter.control.GenericController.fireIterationStart(GenericController.java:405)
	at org.apache.jmeter.control.GenericController.fireIterEvents(GenericController.java:397)
	at org.apache.jmeter.control.GenericController.next(GenericController.java:158)
	at org.apache.jmeter.control.LoopController.next(LoopController.java:123)
	at org.apache.jmeter.threads.AbstractThreadGroup.next(AbstractThreadGroup.java:87)
	at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:238)
	at java.lang.Thread.run(Unknown Source)
Caused by: java.io.FileNotFoundException: C:\XXXXXXXXX (Accès refusé)
	at java.io.FileInputStream.open0(Native Method)
	at java.io.FileInputStream.open(Unknown Source)
	at java.io.FileInputStream.<init>(Unknown Source)
	at org.apache.jmeter.services.FileServer.createBufferedReader(FileServer.java:419)
	at org.apache.jmeter.services.FileServer.readLine(FileServer.java:345)
	at org.apache.jmeter.services.FileServer.readLine(FileServer.java:329)
	at org.apache.jmeter.services.FileServer.reserveFile(FileServer.java:277)
	... 8 more

Antonio
Comment 1 Antonio Gomes Rodrigues 2016-03-09 13:00:23 UTC
PR 162 commited
Comment 2 Sebb 2016-03-10 00:34:22 UTC
This is not a bug.
Nor do I think it should be implemented as an enhancement.

Why should a missing file name be treated any differently from a missing file?

This will cause problems for a working test plan if the file name is accidentally wiped; far better to fail than to continue.
Comment 3 Antonio Gomes Rodrigues 2016-03-17 07:12:31 UTC
New fix provided with PR 167

Antonio
Comment 4 Vladimir Sitnikov 2016-04-02 12:52:30 UTC
Fixed in r1737490