【发布时间】:2020-06-05 14:48:16
【问题描述】:
我在 setUpThread 组中有一个 BeanShell 后处理器来捕获 cookie,并在主线程(作为第一步)中有一个 Beanshell 预处理器来使用在之前的 setUpThread 中捕获的 cookie,例如:
如果我从 JSR223 或 Beanshell 采样器添加 2 行采样器,尽管在支付线程的 UDV 部分中声明了 CFLAG,但我收到以下错误:
错误 o.a.j.u.BeanShellInterpreter:调用 bsh 方法时出错:eval 源文件:内联评估:import org.apache.jmeter.protocol.http.control.CookieManager; import org.apache. . . . '' : Typed variable declaration : Error in method invocation: Method getCookieManager() not found in class'org.apache.jmeter.protocol.java.sampler.JSR223Sampler'
2020-06-05 15:37:44,168 WARN o.a.j.m.BeanShellPreProcessor: Problem in BeanShell script. org.apache.jorphan.util.JMeterException: Error invoking bsh method: eval Sourced file: inline evaluation of:import org.apache.jmeter.protocol.http.control.CookieManager;导入 org.apache。 . . . '':类型变量声明:方法调用错误:方法 getCookieManager() not found in class'org.apache.jmeter.protocol.java.sampler.JSR223Sampler'
【问题讨论】:
-
此错误出现在任何后续采样器中,例如 JSR223/BSH/.. 但它不会停止脚本(意味着它不是显示停止器)
标签: jmeter