CommandLineTool Plugin - Is it possible to specify alternate jmeter.properties file?

624 views
Skip to first unread message

rob...@gmail.com

unread,
Jul 24, 2013, 2:57:45 PM7/24/13
to jmeter-...@googlegroups.com
I noticed that if rename C:\apache-jmeter-2.9\bin\jmeter.properties to say XXjmeter.properties I get error below.

So this got me wondering, why does the CommandLineTool plugin need/reference in file and if an alternate location could be specified like the jmeter switch -p.

I ask for we do use a customized jmeter.properties file in our automation.  So if CommandLineTool does not use anything in jmeter.properties then I could just not worry about it.

Thank you.

------
here is the error I see.....


ERROR: java.lang.RuntimeException: Could not read JMeter properties file
*** Problem's technical details go below ***
Home directory was detected as: C:\apache-jmeter-2.9\lib\ext
Exception in thread "main" java.lang.RuntimeException: Could not read JMeter pro
perties file
        at org.apache.jmeter.util.JMeterUtils.loadJMeterProperties(JMeterUtils.j
ava:190)
        at kg.apc.jmeter.PluginsCMDWorker.initializeProperties(PluginsCMDWorker.
java:91)
        at kg.apc.jmeter.PluginsCMDWorker.prepareJMeterEnv(PluginsCMDWorker.java
:81)
        at kg.apc.jmeter.PluginsCMDWorker.<init>(PluginsCMDWorker.java:55)
        at kg.apc.cmdtools.ReporterTool.processParams(ReporterTool.java:64)
        at kg.apc.cmdtools.PluginsCMD.processParams(PluginsCMD.java:63)
        at kg.apc.cmdtools.PluginsCMD.processParams(PluginsCMD.java:23)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at kg.apc.cmd.UniversalRunner.main(UniversalRunner.java:175)
\AggregateReport TXT file done. return status code: 1

Andrey Pohilko

unread,
Jul 25, 2013, 6:56:12 AM7/25/13
to jmeter-...@googlegroups.com, rob...@gmail.com
CMDTool requires jmeter.properties, because it uses JMeter core classes to parse JTL files. 

I suggest you not modifying jmeter.properties file at all and use user.properties files instead. Those files are intended for per-user changes. Jmeter will search user.properties file in current start directory.

There is not command-line switches to pass different JMeter.properties file for cmdtool.

среда, 24 июля 2013 г., 22:57:45 UTC+4 пользователь rob...@gmail.com написал:

rob...@gmail.com

unread,
Jul 31, 2013, 10:34:01 AM7/31/13
to jmeter-...@googlegroups.com, rob...@gmail.com
Very good.  I will use your suggestion.
Reply all
Reply to author
Forward
0 new messages