FSchumacher commented on code in PR #5761: URL: https://github.com/apache/jmeter/pull/5761#discussion_r1070581321
########## src/core/src/main/java/org/apache/jmeter/testelement/TestPlan.java: ########## @@ -83,11 +86,23 @@ public void prepareForPreCompile() /** * Fetches the functional mode property - * + * Could be change for no gui test with jmeter property : PROP_FUNCTIONAL_MODE Review Comment: *Can be changed for non-gui test with JMeter property: {@code PROP_FUNCTIONAL_MODE}* ########## xdocs/usermanual/component_reference.xml: ########## @@ -6491,11 +6491,15 @@ Selecting Functional Testing instructs JMeter to save the additional sample inf This increases the resources needed to run a test, and may adversely impact JMeter performance. If more data is required for a particular sampler only, then add a Listener to it, and configure the fields as required. <note>The option does not affect CSV result files, which cannot currently store such information.</note> +<note>For non gui test, you can set the Functional Testing with the jmeter property : jmeter.test_plan.functional_mode (true or false, false default value). This property is not by default in the jmeter.properties</note> +</p> +<p>Also, an option exists here to instruct JMeter to run the <complink name="Thread Group"/> serially rather than in parallel. +<note>For non gui test, you can set the Serially with the jmeter property : jmeter.test_plan.serialize_threadgroups (true or false, false default value). This property is by default not in the jmeter.properties</note> </p> -<p>Also, an option exists here to instruct JMeter to run the <complink name="Thread Group"/> serially rather than in parallel.</p> <p>Run tearDown Thread Groups after shutdown of main threads: if selected, the tearDown groups (if any) will be run after graceful shutdown of the main threads. The tearDown threads won't be run if the test is forcibly stopped. +<note>For non gui test, you can set the Run tearDown Thread Groups after shutdown with the jmeter property : jmeter.test_plan.tearDown_on_shutdown (true or false, true default value). This property is not by default in the jmeter.properties</note> Review Comment: Same as above ########## src/core/src/main/java/org/apache/jmeter/testelement/TestPlan.java: ########## @@ -83,11 +86,23 @@ public void prepareForPreCompile() /** * Fetches the functional mode property - * + * Could be change for no gui test with jmeter property : PROP_FUNCTIONAL_MODE * @return functional mode */ public boolean isFunctionalMode() { - return getPropertyAsBoolean(FUNCTIONAL_MODE); + boolean bFunctionalModeDefault = getPropertyAsBoolean(FUNCTIONAL_MODE); + log.debug("bFunctionalModeDefault=" + bFunctionalModeDefault); + String sIsNonGui = System.getProperty(org.apache.jmeter.JMeter.JMETER_NON_GUI); Review Comment: Same for the *s*. Plus, it is probably not needed, when we use the Method `Boolean.getBoolean(string)`, which combines the lookup of the system property and the conversion to a Boolean. ########## xdocs/usermanual/properties_reference.xml: ########## @@ -1568,6 +1568,21 @@ JMETER-SERVER</source> confirmation dialogue.<br/> Defaults to: <code>false</code> </property> +<property name="jmeter.test_plan.serialize_threadgroups"> + For non gui test, set the following value to <code>true</code> in order to set + Run Thread Groups consecutively at the Test Plan level. Not in the jmeter.properties file but in parameter like : jmeter -n -Jjmeter.test_plan.serialize_threadgroups=[true/false] -t script.jmx<br/> + Defaults to: <code>false</code> +</property> +<property name="jmeter.test_plan.functional_mode"> + For non gui test, set the following value to <code>true</code> in order to set + Functional Test Mode at the Test Plan level. Not in the jmeter.properties file but in parameter like : jmeter -n -Jjmeter.test_plan.functional_mode=[true/false] -t script.jmx<br/> Review Comment: ```suggestion Functional Test Mode at the Test Plan level. Not in the <code>jmeter.properties</code> file but in parameter like: <code>jmeter -n -Jjmeter.test_plan.functional_mode=[true/false] -t script.jmx</code><br/> ``` ########## src/core/src/main/java/org/apache/jmeter/testelement/TestPlan.java: ########## @@ -83,11 +86,23 @@ public void prepareForPreCompile() /** * Fetches the functional mode property - * + * Could be change for no gui test with jmeter property : PROP_FUNCTIONAL_MODE * @return functional mode */ public boolean isFunctionalMode() { - return getPropertyAsBoolean(FUNCTIONAL_MODE); + boolean bFunctionalModeDefault = getPropertyAsBoolean(FUNCTIONAL_MODE); Review Comment: For a method-local variable I would not use *b* as a prefix to mark the variable as a boolean. If the method is so long or complex, that I can't remember it is a boolean, it should be shortened :) For global variables I would not use the prefix, as Java has really good IDE support, which shows those information already ;) ########## src/core/src/main/java/org/apache/jmeter/testelement/TestPlan.java: ########## @@ -196,11 +226,22 @@ public String getTestPlanClasspath() { /** * Fetch the serialize threadgroups property - * + * Could be change for no gui test with jmeter property : PROP_SERIALIZE_THREADGROUPS * @return serialized setting */ public boolean isSerialized() { - return getPropertyAsBoolean(SERIALIZE_THREADGROUPS); + boolean bSerializedThreadGroupDefault = getPropertyAsBoolean(SERIALIZE_THREADGROUPS); Review Comment: This seems to be the third replication of the logic to override a value by another value, if non-gui mode is detected and log those decisions. Might be replaced by a general (private) method. ########## src/core/src/main/java/org/apache/jmeter/testelement/TestPlan.java: ########## @@ -83,11 +86,23 @@ public void prepareForPreCompile() /** * Fetches the functional mode property - * Review Comment: If we want to keep the space to be visible, we should add something like `<br>` or `<p>`. ########## src/core/src/main/java/org/apache/jmeter/testelement/TestPlan.java: ########## @@ -83,11 +86,23 @@ public void prepareForPreCompile() /** * Fetches the functional mode property - * + * Could be change for no gui test with jmeter property : PROP_FUNCTIONAL_MODE * @return functional mode */ public boolean isFunctionalMode() { - return getPropertyAsBoolean(FUNCTIONAL_MODE); + boolean bFunctionalModeDefault = getPropertyAsBoolean(FUNCTIONAL_MODE); + log.debug("bFunctionalModeDefault=" + bFunctionalModeDefault); + String sIsNonGui = System.getProperty(org.apache.jmeter.JMeter.JMETER_NON_GUI); + boolean bFunctionalModeReturn = bFunctionalModeDefault; + if ("true".equals(sIsNonGui)) { Review Comment: ```suggestion if (Boolean.getBoolean(org.apache.jmeter.JMeter.JMETER_NON_GUI)) { ``` ########## xdocs/usermanual/component_reference.xml: ########## @@ -6491,11 +6491,15 @@ Selecting Functional Testing instructs JMeter to save the additional sample inf This increases the resources needed to run a test, and may adversely impact JMeter performance. If more data is required for a particular sampler only, then add a Listener to it, and configure the fields as required. <note>The option does not affect CSV result files, which cannot currently store such information.</note> +<note>For non gui test, you can set the Functional Testing with the jmeter property : jmeter.test_plan.functional_mode (true or false, false default value). This property is not by default in the jmeter.properties</note> +</p> +<p>Also, an option exists here to instruct JMeter to run the <complink name="Thread Group"/> serially rather than in parallel. +<note>For non gui test, you can set the Serially with the jmeter property : jmeter.test_plan.serialize_threadgroups (true or false, false default value). This property is by default not in the jmeter.properties</note> Review Comment: ```suggestion <note>For non-GUI test, you can set the Serial mode with the JMeter property: <code>jmeter.test_plan.serialize_threadgroups</code> (<code>true</code> or <code>false</code>, default value is <code>false</code>). This property is not set by default in the <code>jmeter.properties</code> file.</note> ``` ########## xdocs/usermanual/component_reference.xml: ########## @@ -6491,11 +6491,15 @@ Selecting Functional Testing instructs JMeter to save the additional sample inf This increases the resources needed to run a test, and may adversely impact JMeter performance. If more data is required for a particular sampler only, then add a Listener to it, and configure the fields as required. <note>The option does not affect CSV result files, which cannot currently store such information.</note> +<note>For non gui test, you can set the Functional Testing with the jmeter property : jmeter.test_plan.functional_mode (true or false, false default value). This property is not by default in the jmeter.properties</note> Review Comment: Unlike in French typography, no space is put before the colon in English typography. ```suggestion <note>For non-GUI test, you can set the Functional Testing mode with the JMeter property: <code>jmeter.test_plan.functional_mode</code> (<code>true</code> or <code>false</code>, default value is <code>false</code>). This property is not by default in the <code>jmeter.properties</code> file.</note> ``` ########## xdocs/usermanual/properties_reference.xml: ########## @@ -1568,6 +1568,21 @@ JMETER-SERVER</source> confirmation dialogue.<br/> Defaults to: <code>false</code> </property> +<property name="jmeter.test_plan.serialize_threadgroups"> + For non gui test, set the following value to <code>true</code> in order to set + Run Thread Groups consecutively at the Test Plan level. Not in the jmeter.properties file but in parameter like : jmeter -n -Jjmeter.test_plan.serialize_threadgroups=[true/false] -t script.jmx<br/> Review Comment: ```suggestion Run Thread Groups consecutively at the Test Plan level. Not in the <code>jmeter.properties</code> file but in parameter like: <code>jmeter -n -Jjmeter.test_plan.serialize_threadgroups=[true/false] -t script.jmx</code><br/> ``` ########## xdocs/usermanual/properties_reference.xml: ########## @@ -1568,6 +1568,21 @@ JMETER-SERVER</source> confirmation dialogue.<br/> Defaults to: <code>false</code> </property> +<property name="jmeter.test_plan.serialize_threadgroups"> + For non gui test, set the following value to <code>true</code> in order to set + Run Thread Groups consecutively at the Test Plan level. Not in the jmeter.properties file but in parameter like : jmeter -n -Jjmeter.test_plan.serialize_threadgroups=[true/false] -t script.jmx<br/> + Defaults to: <code>false</code> +</property> +<property name="jmeter.test_plan.functional_mode"> + For non gui test, set the following value to <code>true</code> in order to set + Functional Test Mode at the Test Plan level. Not in the jmeter.properties file but in parameter like : jmeter -n -Jjmeter.test_plan.functional_mode=[true/false] -t script.jmx<br/> + Defaults to: <code>false</code> +</property> +<property name="jmeter.test_plan.tearDown_on_shutdown"> + For non gui test, set the following value to <code>true</code> in order to set + Run tearDown Thread Groups after shutdown of main threads at the Test Plan level. Not in the jmeter.properties file but in parameter like : jmeter -n -Jjmeter.test_plan.tearDown_on_shutdown=[true/false] -t script.jmx <br/> Review Comment: ```suggestion Run tearDown Thread Groups after shutdown of main threads at the Test Plan level. Not in the <code>jmeter.properties</code> file but in parameter like: <code>jmeter -n -Jjmeter.test_plan.tearDown_on_shutdown=[true/false] -t script.jmx</code><br/> ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@jmeter.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org