Jmeter, a performance tool, starts with the SpringBoot project
"This is the 15th day of my participation in the Gwen Challenge in November. Check out the details: The Last Gwen Challenge in 2021."
Jmeter performance test is usually executed under Linux through the command line. In order to exercise my code and logic ability, I want to know whether Jmeter can be started by springBoot project. I tried to write it at home on weekends. There are still problems to deal with, the following is the corresponding code, in fact, there are online, but the key is to consciously collect knowledge, to use the time can be used to change.
Jmeter needs to be configured in Linux and Java environment variables need to be configured:
# # editor vi ~/.bash_profile # jmeter: The path changes according to your situationJMETER_HOME = / root/tools/apache jmeter - 5.1.1 PATH =$PATH:$HOME/bin:$JMETER_HOME/bin: export PATH ## Execution takes effect source ~/.bash_profile Copy the code
Click upload script, and the dialog box pops up. Click Upload, and the background log shows that the upload is successful.
Click Start and read the startup log.
Access - Call JAVA code - Start shell command - Start Jmeter - get the start log
The front-end code
The following reference code: