Golang
Golang
foxtool23
用户体验第一
展开
-
Golang 并发限制5个协成工作
package main import ( "fmt" "time" "strconv" "net/http" "io/ioutil" ) func main() { count := make(chan int, 10) for i := 1; i < 2000000; i++ { count <- 1 go func(i int) { run(i) .原创 2020-05-28 17:35:17 · 538 阅读 · 0 评论 -
golang jwt token
package utils import ( "errors" "github.com/astaxie/beego" "github.com/dgrijalva/jwt-go" "time" ) type TokenClaims struct { jwt.StandardClaims Uid int64 `json:"uid"` Uname ...原创 2020-04-14 10:20:27 · 358 阅读 · 0 评论