Hardware test
Hardware test
memtest86+
stress
smartmontools
sysstat
hdparm
vnstat
nload
mpstat -P ALL 1
iostat -x 1
nload
Reference
mongodb
mongodb
db.serverStatus().connections
dt.serverStatus().locks;
rs.printReplicationInfo();
rs.printSlaveReplicationInfo();
rs.printSecondaryReplicationInfo();
db.currentOp({ “waitingForLock”: true });
db.setProfilingLevel(1, 50)
db.system.profile.find().sort({ ts: -1 }).limit(5).pretty()
db.mycollection.find({ field: value }).explain(“executio...
CentOS EOL
CentOS EOL
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
sudo curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo
sudo yum install iperf3
Reference
FastAPI profiler
FastAPI profiler
- args:
- --reduced-profile
- --profile-interval
- "300"
- --outfile
- profile_report.txt
- runfastapi.py
command:
- scalene
env:
Reference
plasma-umass/scalene
benfred/py-spy
Web test
Web test
Selenium: Selenium is widely used for browser automation and can handle complex interactions with dashboards and filters. It supports many languages (like Python, JavaScript, and Java) and integrates well with test frameworks like Pytest or JUnit.
Playwright: This is a modern, powerful framework by Microsoft for end-to-end testing. Pl...
build aws lambda function
build aws lambda function
Reference
Deploy Python Lambda functions with container images
mongodb stop old openration
mongodb stop old openration
当客户端断开连接时, 如果是aggregations 和 find操作, 则会自动停止该操作; 如果是写操作, 那么会继续执行; 见https://www.mongodb.com/docs/drivers/node/current/faq/#what-happens-to-running-operations-if-the-client-disconnects-
如果是前端取消操作, 或者重新开始新的操作在FastAPI中, 不会中止之前的操作, 所以不会中止之前的MongoDB操作;
手动停止MongoDB操作
使用db.currentOp()方法可以查看当前正在执行的MongoDB操作;
使用db.kill...
463 post articles, 58 pages.