上一页 1 2 3 4 5 6 ··· 29 下一页
摘要: 使用WireShark抓包,选择TCP报文,TCP是一种安全的协议,在网络出现状况时也能安全稳定的传输数据,但是在网络出现问题时tcp报文中会有很多中情况导致报文重传或者是重组。现在就在报文中遇到的几个问题来详细说明一下。WireShark出现的常见提示TCP Out_of_Order的原因分析:一 阅读全文
posted @ 2020-09-18 11:36 闲云-野鹤 阅读(2087) 评论(0) 推荐(0) 编辑
摘要: nginx反向代理WebSocket WebSocket工作在HTTP的80和443端口并使用前缀ws://或者wss://进行协议标注,在建立连接时使用HTTP/1.1的101状态码进行协议切换, 当前标准不支持两个客户端之间不借助HTTP直接建立Websocket连接。 map $http_up 阅读全文
posted @ 2020-09-04 11:42 闲云-野鹤 阅读(477) 评论(0) 推荐(0) 编辑
摘要: func Encode(data []byte) []byte { buf := bytes.NewBuffer(nil) binary.Write(buf, binary.BigEndian, uint32(len(data))) binary.Write(buf, binary.BigEndia 阅读全文
posted @ 2020-08-08 23:42 闲云-野鹤 阅读(254) 评论(0) 推荐(0) 编辑
摘要: 利用ajax下载文件。很早之前,我们下载文件,都是通过链接链接,跳转到目标页,然后下载,自从h5出来了,我们就可以用高级api 通过ajax下载了 axios({ url: 'http://localhost:5000/static/example.pdf', method: 'GET', resp 阅读全文
posted @ 2020-07-24 15:28 闲云-野鹤 阅读(267) 评论(0) 推荐(0) 编辑
摘要: func initPool(server, pass string, database int) *redis.Pool { return &redis.Pool{ MaxIdle: 80, MaxActive: 12000, Dial: func() (redis.Conn, error) { c 阅读全文
posted @ 2020-06-01 10:42 闲云-野鹤 阅读(1440) 评论(0) 推荐(0) 编辑
摘要: 在使用puppeteer的时候添加代理的时候总是遇到 ERR_NO_SUPPORTED_PROXIES (async () => { const browser = await puppeteer.launch({ headless: false, args: [ '--proxy-server=h 阅读全文
posted @ 2020-05-07 10:58 闲云-野鹤 阅读(4525) 评论(0) 推荐(0) 编辑
摘要: 基本概念 先说一下关于用户、验证和角色的基本概念。 用户 要在MongoDB中验证客户端,必须向MongoDB添加相应的用户。 添加用户 添加用户使用MongoDB的用户管理接口,此接口提供db.createUser()的方式添加用户(这里有坑,网络上很多关于MongoDB添加用户的内容还都在使用d 阅读全文
posted @ 2020-04-21 16:34 闲云-野鹤 阅读(274) 评论(0) 推荐(0) 编辑
摘要: 在docker安装php的intl拓展的时候 报缺少icu。发现容器使用的apline linux 于是就google找到了 方法 apk add icu-dev 在RedHat/Centos下可以使用 # yum install libicu-devel 在Ubuntu/Debian下可以使用 a 阅读全文
posted @ 2020-04-17 15:23 闲云-野鹤 阅读(950) 评论(0) 推荐(0) 编辑
摘要: dstf, err := os.Create("./data/" + fileName) defer dstf.Close() if err != nil { beego.Error("create file error: " + err.Error()) return "", err } dstf 阅读全文
posted @ 2020-03-19 10:46 闲云-野鹤 阅读(753) 评论(0) 推荐(0) 编辑
摘要: 1. 检测命令是否存在 不使用which ,which不是内建命令,可能不同的平台实现不一样。 2. 检测元素是否在数组里 阅读全文
posted @ 2020-01-08 11:08 闲云-野鹤 阅读(125) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 29 下一页