jmeter和metersphere引用jar包报错Error invoking bsh method和 not found in namespace

2024-01-09 09:26:38 ERROR 54b7e26f 1-1 Error invoking bsh method: eval Sourced file: inline evaluation of: // BeanShell脚本开始 import com.example.demo.DemoApplication; DemoApplica . . . '' : Typed variable declaration : Class: DemoApplication not found in namespace 2024-01-09 09:26:38 WARN 54b7e26f 1-1 Exception executing script. org.apache.jorphan.util.JMeterException: Error invoking bsh method: eval Sourced file: inline evaluation of: // BeanShell脚本开始 import com.example.demo.DemoApplication; DemoApplica . . . '' : Typed variable declaration : Class: DemoApplication not found in namespace

1.查看jar包有没有上传

2.引用包名.类名.方法名

3.查看包是否引用第三方依赖,如果有打包的是需要依赖一起打包

pom文件里面配置:

复制代码
          <plugin>  
              <artifactId>maven-assembly-plugin</artifactId>  
              <configuration>  
                  <!--这部分可有可无,加上的话则直接生成可运行jar包-->
                  <!--<archive>-->
                      <!--<manifest>-->
                          <!--<mainClass>${exec.mainClass}</mainClass>-->
                      <!--</manifest>-->
                  <!--</archive>-->
                  <descriptorRefs>  
                      <descriptorRef>jar-with-dependencies</descriptorRef>  
                  </descriptorRefs>  
             </configuration>
        </plugin>
相关推荐
曾经的三心草3 天前
微服务的编程测评系统11-jmeter-redis-竞赛列表
redis·jmeter·微服务
天才测试猿3 天前
常见的Jmeter压测问题
自动化测试·软件测试·python·测试工具·jmeter·职场和发展·压力测试
小小工匠4 天前
Maven - Spring Boot 项目打包本地 jar 的 3 种方法
spring boot·maven·jar·system scope
张永清-老清4 天前
《JMeter核心技术、性能测试与性能分析》 教学大纲及标准
jmeter·性能优化
kakwooi4 天前
易乐播播放器---压力测试
java·jmeter·测试
张永清5 天前
《JMeter核心技术、性能测试与性能分析》 教学大纲及标准
jmeter·性能测试·性能调优·性能分析·教材
哈哈孝子5 天前
JMeter性能测试详细版(适合0基础小白学习--非常详细)
功能测试·jmeter
川石课堂软件测试5 天前
JMeter并发测试与多进程测试
功能测试·jmeter·docker·容器·kubernetes·单元测试·prometheus
sunshine__sun5 天前
JMeter 测试 WebSocket 接口的详细教程
websocket·网络协议·jmeter
明天不吃。6 天前
【软件测试】性能测试 —— 工具篇 JMeter 介绍与使用
jmeter