Go语言中文网 为您找到相关结果 31

微信中继服务器https://github.com/1046102779/wx_relay_server

# 微信中继服务器 目的:其他服务采用拉服务模式,通过rpcx进行rpc通信,获取相关微信token. 用户微信公众号第三方平台刷公众号平台和托管的公众号appid的相关token, 该服务不能停超过10分钟. 主要刷公众号第三方平台的component_access_token和preauthcode, 公众号的authorizer_access_token和authorizer_refresh_token 存储方式:etcd存储rpc服务地址和微信公众号平台和公众号token, 使用etcd的ttl特性,并watch并刷新 ## 新增服务的可靠性措施 1. 服务启动后,立即读取etcd中的所有微信公众平台和公众号数据,加载到内存中。 并监听所有token ...阅读全文

Golang实现通过微信接收告警消息

首先需要注册微信企业公众号,选团队的可以不使用认证 如图进入公众平台 选择设置.里面有CorpID 和 SecretID 这个发送的时候需要用到. 下面就是使用提供的API 开始发送信息了.具体自己可以看开发者中心里面的文档. package main import ( "bufio" "bytes" "encoding/json" "errors" "flag" "io/ioutil" "net/http" "os" ) const ( //发送消息使用导的url sendurl = `https://qyapi.weixin.qq.com/cgi-bin/message/send?access_token=` //获取token使用导的url get_token = `https://q...阅读全文

博文 2016-09-12 16:00:02 fyxichen

Centos 6.7安装docker-engine-1.7.1-1.el6.x86_64.rpm

在安装完成后执行 service docker start 任然没有启动,查看错误日志发现如下错误 cat /var/log/docker time="2019-03-20T06:48:53.939998118Z" level=warning msg="You are running linux kernel version 2.6.32-573.26.1.el6.x86_64, which might be unstable running docker. Please upgrade your kernel to 3.10.0." time="2019-03-20T06:48:53.960733120Z" level=info msg="Listening for HTTP on uni...阅读全文

博文 2019-03-20 15:35:21 goxgo

Jupyter 笔记本的 Go 内核 gophernotes

### gophernotes - Go in Notebooks gophernotes is a Go kernel for Jupyter notebooks. Finally, we can have a reliable and maintained way to use Go interactively and code in the browser. Use gophernotes to create and share documents that contain live Go code, equations, visualizations and explanatory text. These notebooks, with the live Go code, can...阅读全文

Dubbo的微内核机制

Wikipedia上微内核(Microkernel)的定义In computer science, a microkernel (also known as μ-kernel) is the near-minimum amount of software that can provide the mechanisms needed to implement an operating system (OS). These mechanisms include low-level address space management, thread management, and inter-process communication (IPC). If the hardware provides ...阅读全文

博文 2018-09-16 21:40:32 Java1122zzz

计算机基础知识-计算机组成与原理

计算机发展简史阶段:电子管计算机 > 晶体管计算机 > 集成电路计算机(操作系统出现)> 超大规模集成电路计算机(微型计算机)特点:体积越来越小 集成度越快 运算效率更高 功耗低越来越低计算机分类1.超级计算机(用于国家尖端技术 每秒10000亿次浮点运算)2.大型计算机 (具有高性能 可处理大量数据与复杂的运算)3.迷你计算机 (服务器)4.工作站 (体积大 性能强劲)5.微型计算机 (个人计算机)计算机的体系与结构冯诺依曼体系:将程序指令和数据一起存储的计算机设计概念结构发展过程:早期计算机仅含固定程序计算机 > 更改程序更改结构重新设计电路 > 把程序存储起来并设计通用电路组成:存储器 + 控制器 + 输入设备 + 输出设备现代计算机结构(解决了冯诺依曼瓶颈 主要解决cpu 与 存储设...阅读全文

微信golang签名算法

type WXPrams struct { m map[string]interface{} // 参数 sign string // 签名 } func (p *WXPrams) InitSign() { var keys []string for k, _ := range p.m { keys = append(keys, k) } sort.Strings(keys) builder := strings.Builder{} for _, v := range keys { builder.WriteString(v) builder.WriteString("=") builder.WriteString(fmt.Sprint(p.m[v])) builder.WriteStrin...阅读全文

博文 2019-01-02 19:34:46 AlberLiu

13位的时间golang

UnixNano纳秒要转换成毫秒, 进6个位 1 纳秒 = 1000皮秒 1,000 纳秒 = 1微秒 μs 1,000,000 纳秒 = 1毫秒 ms 1,000,000,000 纳秒 = 1秒 s t := strconv.FormatInt(time.Now().UnixNano()/1e6, 10) fmt.Println(len(t)) // 13 fmt.Println(t) // 1588733947147 fmt.Println(fmt.Sprint(1e6)) // 1*10^6= 100000...阅读全文

博文 2020-05-06 11:32:50 百里江山