【问题标题】:Not able to see the response by executing curl command in OS process sampler of Jmeter无法通过在 Jmeter 的 OS 进程采样器中执行 curl 命令来查看响应
【发布时间】:2018-11-24 04:23:30
【问题描述】:

当我使用 curl 命令时

curl -s https://www.google.com/

通过 jmeter 中的 os process sampler,我可以在 ViewResultsTree 中看到响应。

但是,在从 os process sampler 运行以下命令时,我在 ViewResultsTree 的响应中看不到任何内容。该 url 是我们内部的,需要证书来验证。

curl -s -kX GET -H 'Accept: application/json' --cert 'abc.crt:<passphrase>' --key 'abc.key' https://example.com/accounts/12345/statuses

相同的 curl 命令,如果我从命令行(即终端)运行,我可以看到响应为 json。

有什么遗漏吗?

【问题讨论】:

    标签: curl jmeter jmeter-plugins jmeter-3.2


    【解决方案1】:

    我通过在 shell 脚本中嵌入 curl 命令并从 OS 进程采样器运行 shell 脚本来解决问题,它工作正常

    【讨论】:

      猜你喜欢
      • 2018-06-14
      • 1970-01-01
      • 1970-01-01
      • 2021-04-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多