2022年5月23日
参考 JMeter 文档中的 notes_on_extending.txt Making a TestBean Plugin For JMeter This component will be a CSV file reading element that will let users easily vary their input data using csv files. Pick a package and make three files: [ComponentName].java (org.apache.jmeter.config.CSVDataSet.java) [ComponentName]BeanInfo.java (org.apache.jmeter.config.CSVDataSetBeanInfo.java) [ComponentName]Resources.properties (org.apache.jmeter.config.CSVDataSetResources.properties) CSVDataSet.java must implement the TestBean interface. In addition, it will extend ConfigTestElement, and implement LoopIterationListener. - TestBean is a marker interface, so there are no methods to implement. - Extending ConfigTestElement will make our component a Config element in a test plan. By extending different abstract classes, you can control the type of element your component will be (ie AbstractSampler, AbstractVisualizer, GenericController, etc - though you can also make different types of elements just by instantiating the right interfaces, the abstract classes can make your life easier). CSVDataSetBeanInfo.java should extend org.apache.jmeter.testbeans.BeanInfoSupport create……
阅读全文
2022年5月23日
问题背景 在个人的 Mac Book Pro 上面,开启了 easyVPN 后,运行带有自开发的禅道用例测试结果同步后端监听器的 JMeter 时,是可以正常连接到禅道的测试数据库的。 但是在 windows 10 及以上版本,同样的开启了 easyVPN 后,运行则无法连接到数据库。一直提示 com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure 初步分析,以为是不同 VPN 账号的权限问题。可是用自己的 vpn 账号登录到 wind……
阅读全文
2022年5月13日
参考https://zhuanlan.zhihu.com/p/110154333 配置 jmeter influxdbUrl :http://localhost:8086/write?db=jmeter 如果你的 jmeter 也是在 docker 中运行的话,使用 http://host.docker.internal:8086/write?db=jmeter #host 写安装 influxdb 服务的 ip 地址+端口,如修改填写修改后的端口 db 创建数据库:jmeter application……
阅读全文
2022年5月7日
参考 https://www.jianshu.com/p/3e1272357935……
阅读全文
2022年5月7日
version: "3.7" services: # http/2 server caddy: image: caddy:2.4.6-alpine container_name: caddy restart: unless-stopped network_mode: "host" environment: - TZ=Asia/Shanghai - agree - email=your-email@test.com volumes: - "~/docker/caddy/conf/Caddyfile:/etc/Caddyfile" - "~/docker/caddy/.caddy:/root/.caddy" - "~/docker/caddy/logs:/opt/logs" - "~/docker/caddy/www:/opt/www" ports: - 80:80 - 443:443……
阅读全文
2022年5月3日
MYSQL8 的新认证方式 在 MySQL8.0 版本之前,MySQL 使用的加密方式是mysql_native_password。在 MySQL8.0 之后,加密的方式改为caching_sha2_password,从字面意思理解,后者的加密方式应该更高效,以便提升客户端的连接速度。 MYSQL 8 修改用户的密码 由于部分客户端对 mysql8 的新认证方……
阅读全文
2022年4月27日
图形界面的 The Unarchive 在 mac os 的 AppStore 搜索 Unarchive 即可。 官方的命令行工具 rar/unrar (试用版) 下载命令行工具包https://www.rarlab.com,只有 600K 左右。 双击即可直接解压,或生成一个 rar 的文件夹 使用 iTerm2 进入该文件夹命令行窗口,安装 rar 和 unrar 这两个命令: # 安装 rar 压缩命令 sudo install -c -o $USER rar /usr/local/bin/ # 安装 unrar 解压缩命令 sudo install……
阅读全文
2022年4月27日
准备工作 假设你已经下载并安装好如下软件: java8 maven IDEA 使用 idea 创建 maven 项目工程 添加 jmeter 测试脚本 在 src/test文件夹内创建jmeter文件夹用于存放 jmeter 测试脚本。可以使用子文件夹,无需将 jmeter 这个文件夹的类型设置为 test。 修改 pom.xml 添加 jmeter 插件 (重点) maven 集成 jmeter-maven-plugin 可以运行自动化测试。 <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>org.example</groupId> <artifactId>jxyx-app-testing</artifactId>……
阅读全文
2022年4月24日
关于自动化接口测试及过程管理的思考 对接口自动化需要讨论的一些内容: 根据生产环境(或测试环境)导出一份 sql dump 的数据,业务持续发展时测试数据基准如何跟进(即自动测试的数据库的结构与数据始终保持到最新,或有其他更好的策略)? docker mysql 数据直接存放在容器内(一次性,下次新启动则是原始数据),还是……
阅读全文
2022年4月24日
windows/mac 平台连接方式 windows 和 mac 都是通过host.docker.internal去连接宿主机。 当你启动了一个 docker web 服务,需要修改 docker web 使用的 mysql 地址,将 localhost 改成 host.docker.internal 即可。 linux 平台连接方式 通过获取 docker 内部的网关获取到宿主机的 ip: docker inspect <container-id-or-name> | grep Gateway "Gateway": "", "IPv6Gateway": "", "Gateway": "172.18.0.1", "IPv6Gateway": "", 对于本例中 docker 应用程序使用的 MySQL 指向宿主机的 172.18.0.1:3306……
阅读全文