- 博客(11)
- 收藏
- 关注
原创 redLock与redis实现并发控制
多个并发,下一个请求依赖上一个请求的处理结果,因此需求让多个并发处于队列中,依次执行。egg.js + nodejs包redlock + redis。
2024-04-09 15:46:18
198
原创 ssh2实现远程连接机器webShell
4.前端部分,使用vue2+elementUI+socket.io-client。1. nodejs使用ssh2连接shell,简单交互。3.结合egg-socket.io实现前后端交互。示例:使用conn.shell。2. 使用xterm设置宽高。
2023-04-19 15:07:08
728
原创 element-ui的table实现高度自适应
1.最外层div使用flex部署。2.第二层使用calc计算高度。3.最后设置表格的height="100%"
2023-04-07 14:57:02
1825
原创 错误排查记录: egg插件开发报can‘t overwrite property
egg插件开发loader\file_loader.js报can't overwrite property
2021-11-26 21:30:52
672
原创 egg 拆分 sequelize 日志
egg中使用插件egg-sequelize会生成很多的sequelize日志,混淆在打印的logger里如下:拆分生成环境的sequelize日志到egg-sequelize中:在config/config.prod.js中:因为获取不到 ctx.logger 对象,所以引用egg-logger中的FileTransfer生成日志配置import { EggAppConfig, PowerPartial, EggAppInfo } from 'egg';const Logg.
2021-10-29 17:53:05
699
原创 踩坑:vue项目js文件报store undefined
文件目录大致为:src api.jsstore modules content.js utils.jsutils.js中:import store from '@/store'console.log(store)store.commit('SET_HOST', location.hostname)export isLocal = location.hostname === 'localhost'api.js中:import...
2021-10-29 16:28:25
3758
4
转载 egg socket-io报failed: WebSocket is closed before the connection is established 解决
配置文件package.json修改启动命令, 添加 ----sticky
2021-07-28 16:35:27
3837
1
原创 mySql无法查找ip格式的字段解决
问题:select * from xxx_table where ins_ip = 192.168.10.110;Error Code: 1064. You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '.10.110' at line 1 0.000 sec解决:给...
2021-07-26 22:06:15
152
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人