gpt4 book ai didi

jmeter - 将文件夹中的所有 jar 添加到 jmeter 类路径

转载 作者:行者123 更新时间:2023-12-02 02:22:34 27 4
gpt4 key购买 nike

我有一个 CI 服务器,将多个应用程序 jar 及其各种依赖项转储到一个文件夹中。然后我尝试使用 jmeter 类路径中的所有 jar 运行 jmeter 测试。

我可以将 jmeter 的 user.classpath 属性设置为以(半)冒号分隔的各个 jar 列表,但似乎不支持使用通配符。有没有办法将整个文件夹的 jar 添加到 jmeter 的类路径中?

最佳答案

根据 How to Use JUnit With JMeter guide:

You can also “tell” JMeter to look into additional locations via the “user.classpath” property. This property lives in the “user.properties” file under the /bin folder of your JMeter installation. It can take the following values:

  • Single jar file: user.classpath=/Projects/junit/test1.jar
  • Multiple jar files: user.classpath=/Projects/junit/test1.jar;/Projects/junit/test2.jar
  • A folder: user.classpath=/Projects/junit
  • Any combination of the above. Individual classpath entries need to be separated by semicolon or colon depending on underlying operating system

这篇文章是关于 JUnit 的,但是类加载和类路径配置适用于任何外部 .jar 文件。

请记住,更改类路径不是动态过程,您需要重新启动 JMeter 才能选择任何新的 jar 或属性更改。

关于jmeter - 将文件夹中的所有 jar 添加到 jmeter 类路径,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29399808/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com