go-zero is a web and rpc framework written in Go. It's born to ensure the stability of the busy sites with resilient design. Builtin goctl greatly improves the development productivity.

Overview

go-zero

English | 简体中文

Go codecov Go Report Card Release License: MIT

0. what is go-zero

go-zero is a web and rpc framework that with lots of engineering practices builtin. It’s born to ensure the stability of the busy services with resilience design, and has been serving sites with tens of millions users for years.

go-zero contains simple API description syntax and code generation tool called goctl. You can generate Go, iOS, Android, Kotlin, Dart, TypeScript, JavaScript from .api files with goctl.

Advantages of go-zero:

  • improve the stability of the services with tens of millions of daily active users
  • builtin chained timeout control, concurrency control, rate limit, adaptive circuit breaker, adaptive load shedding, even no configuration needed
  • builtin middlewares also can be integrated into your frameworks
  • simple API syntax, one command to generate couple of different languages
  • auto validate the request parameters from clients
  • plenty of builtin microservice management and concurrent toolkits

Architecture

1. Backgrounds of go-zero

At the beginning of 2018, we decided to re-design our system, from monolithic architecture with Java+MongoDB to microservice architecture. After researches and comparison, we chose to:

  • Golang based
    • great performance
    • simple syntax
    • proven engineering efficiency
    • extreme deployment experience
    • less server resource consumption
  • Self-designed microservice architecture
    • I have rich experience on designing microservice architectures
    • easy to location the problems
    • easy to extend the features

2. Design considerations on go-zero

By designing the microservice architecture, we expected to ensure the stability, as well as the productivity. And from just the beginning, we have the following design principles:

  • keep it simple
  • high availability
  • stable on high concurrency
  • easy to extend
  • resilience design, failure-oriented programming
  • try best to be friendly to the business logic development, encapsulate the complexity
  • one thing, one way

After almost half a year, we finished the transfer from monolithic system to microservice system, and deployed on August 2018. The new system guaranteed the business growth, and the system stability.

3. The implementation and features of go-zero

go-zero is a web and rpc framework that integrates lots of engineering practices. The features are mainly listed below:

  • powerful tool included, less code to write
  • simple interfaces
  • fully compatible with net/http
  • middlewares are supported, easy to extend
  • high performance
  • failure-oriented programming, resilience design
  • builtin service discovery, load balancing
  • builtin concurrency control, adaptive circuit breaker, adaptive load shedding, auto trigger, auto recover
  • auto validation of API request parameters
  • chained timeout control
  • auto management of data caching
  • call tracing, metrics and monitoring
  • high concurrency protected

As below, go-zero protects the system with couple layers and mechanisms:

Resilience

4. Future development plans of go-zero

  • auto generate API mock server, make the client debugging easier
  • auto generate the simple integration test for the server side just from the .api files

5. Installation

Run the following command under your project:

go get -u github.com/tal-tech/go-zero

6. Quick Start

  1. full examples can be checked out from below:

    Rapid development of microservice systems

    Rapid development of microservice systems - multiple RPCs

  2. install goctl

    goctlcan be read as go control. goctl means not to be controlled by code, instead, we control it. The inside go is not golang. At the very beginning, I was expecting it to help us improve the productivity, and make our lives easier.

    GO111MODULE=on go get -u github.com/tal-tech/go-zero/tools/goctl

    make sure goctl is executable.

  3. create the API file, like greet.api, you can install the plugin of goctl in vs code, api syntax is supported.

    type Request struct {
      Name string `path:"name,options=you|me"` // parameters are auto validated
    }
    
    type Response struct {
      Message string `json:"message"`
    }
    
    service greet-api {
      @handler GreetHandler
      get /greet/from/:name(Request) returns (Response);
    }

    the .api files also can be generate by goctl, like below:

    goctl api -o greet.api
  4. generate the go server side code

    goctl api go -api greet.api -dir greet

    the generated files look like:

    ├── greet
    │   ├── etc
    │   │   └── greet-api.yaml        // configuration file
    │   ├── greet.go                  // main file
    │   └── internal
    │       ├── config
    │       │   └── config.go         // configuration definition
    │       ├── handler
    │       │   ├── greethandler.go   // get/put/post/delete routes are defined here
    │       │   └── routes.go         // routes list
    │       ├── logic
    │       │   └── greetlogic.go     // request logic can be written here
    │       ├── svc
    │       │   └── servicecontext.go // service context, mysql/redis can be passed in here
    │       └── types
    │           └── types.go          // request/response defined here
    └── greet.api                     // api description file
    

    the generated code can be run directly:

    cd greet
    go mod init
    go mod tidy
    go run greet.go -f etc/greet-api.yaml

    by default, it’s listening on port 8888, while it can be changed in configuration file.

    you can check it by curl:

    curl -i http://localhost:8888/greet/from/you

    the response looks like:

    HTTP/1.1 200 OK
    Date: Sun, 30 Aug 2020 15:32:35 GMT
    Content-Length: 0
  5. Write the business logic code

    • the dependencies can be passed into the logic within servicecontext.go, like mysql, reds etc.
    • add the logic code in logic package according to .api file
  6. Generate code like Java, TypeScript, Dart, JavaScript etc. just from the api file

    goctl api java -api greet.api -dir greet
    goctl api dart -api greet.api -dir greet
    ...

7. Benchmark

benchmark

Checkout the test code

8. Documents (adding)

9. Important notes

  • Use grpc 1.29.1, because etcd lib doesn’t support latter versions.

    google.golang.org/grpc v1.29.1

10. Chat group

Join the chat via https://join.slack.com/t/go-zeroworkspace/shared_invite/zt-m39xssxc-kgIqERa7aVsujKNj~XuPKg

Issues
  • 支持客户端使用K8s Service进行服务发现

    支持客户端使用K8s Service进行服务发现

    配置方法

    其中Name、Namespace、Port分为Kubernetes中Service相应的Name、Namespace、Port

    Transform:
      K8s:
        Name: transform-svc
        Namespace: default
        Port: 8081
    
    
    enhancement 
    opened by shiquan1988 28
  • 无法链接本地的etcd客户端 无法写入

    无法链接本地的etcd客户端 无法写入

    {"level":"warn","ts":"2021-08-23T17:23:44.850+0800","logger":"etcd-client","caller":"[email protected]/retry_interceptor.go:62","msg":"retrying of unary invoker failed","target":"etcd-endpoints://0xc0001a1880/#initially=[192.168.1.57:2379]","attempt":0,"error":"rpc error: code = Dead lineExceeded desc = latest balancer error: last connection error: connection error: desc = "transport: Error while dialing dial tcp 0.0.0 .0:2379: connectex: No connection could be made because the target machine actively refused it.""} {"level":"info","ts":"2021-08-23T17:23:44.850+0800","logger":"etcd-client","caller":"[email protected]/client.go:207","msg":"Auto sync endpoints f ailed.","error":"context deadline exceeded"}

    opened by sjfxy 23
  • User-defined metrics in Prometheus is not collected

    User-defined metrics in Prometheus is not collected

    • 增加一个中间件, 自定义一个指标
    const serverNamespace = "golang"
    
    type CheckCustomerUuidMiddleware struct {
    	metric metric.GaugeVec
    }
    
    func NewCheckCustomerUuidMiddleware(env string) *CheckCustomerUuidMiddleware {
    
    	return &CheckCustomerUuidMiddleware{
    		metric: metric.NewGaugeVec(&metric.GaugeVecOpts{
    			Namespace: serverNamespace,
    			Subsystem: "fail",
    			Name:       "_notification",
    			Help:      "template and customer uuid not match.",
    			Labels:    []string{"mid"},
    		}),
    	}
    }
    
    func (m *CheckCustomerUuidMiddleware) Handle(next http.HandlerFunc) http.HandlerFunc {
    	return func(w http.ResponseWriter, r *http.Request) {
    		defer func() {
    			m.metric.Add(1, "33")
    			m.metric.Add(1, "103")
    			m.metric.Set(11, "33")
    			m.metric.Set(11, "103")
    		}()
    
    		next.ServeHTTP(w, r)
    	}
    }
    
    • rest.WithMiddlewares 设置全局中间件

    • 结果: 框架自带的指标数据提交了, 自定义的没有

    • 环境

    • go version go1.16.6 windows/amd64

    • zeromicro/go-zero v1.3.1

    • win 11

    opened by SaneHe 21
  • goctl docker template optimization

    goctl docker template optimization

    Describe the bug goctl docker 生成的模板

    ✦ λ  tree -L 2
    .
    ├── order
    │   ├── api
    │   ├── model
    │   └── rpc
    ├── pay
    │   ├── api
    │   ├── model
    │   └── rpc
    ├── product
    │   ├── api
    │   ├── model
    │   └── rpc
    └── user
        ├── api
        ├── model
        └── rpc
    
    16 directories, 0 files
    

    以go-zero-mall项目为例,进入order/api目录生成Dockerfile (由于goctl docker 没有-o选项只能进入相应的服务目录去运行)

    cd service/order/api
    goctl docker --go order.go --port 9000
    

    在service/order/api 服务有go.mod go.sum 的情况下,该命令生成的是

    FROM golang:alpine AS builder
    
    LABEL stage=gobuilder
    
    ENV CGO_ENABLED 0
    ENV GOPROXY https://goproxy.cn,direct
    
    RUN apk update --no-cache && apk add --no-cache tzdata
    
    WORKDIR /build
    
    ADD go.mod .
    ADD go.sum .
    RUN go mod download
    COPY . .
    COPY ./etc /app/etc
    RUN go build -ldflags="-s -w" -o /app/order ./order.go
    
    
    FROM scratch
    
    COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
    COPY --from=builder /usr/share/zoneinfo/Asia/Shanghai /usr/share/zoneinfo/Asia/Shanghai
    ENV TZ Asia/Shanghai
    
    WORKDIR /app
    COPY --from=builder /app/order /app/order
    COPY --from=builder /app/etc /app/etc
    
    EXPOSE 9000
    
    CMD ["./order", "-f", "etc/order.yaml"]
    

    在service/order/api 服务没有go.mod go.sum 的情况下,该命令生成的是

    FROM golang:alpine AS builder
    
    LABEL stage=gobuilder
    
    ENV CGO_ENABLED 0
    ENV GOPROXY https://goproxy.cn,direct
    
    RUN apk update --no-cache && apk add --no-cache tzdata
    
    WORKDIR /build
    
    ADD go.mod .
    ADD go.sum .
    RUN go mod download
    COPY . .
    COPY service/order/api/etc /app/etc
    RUN go build -ldflags="-s -w" -o /app/order service/order/api/order.go
    
    
    FROM scratch
    
    COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
    COPY --from=builder /usr/share/zoneinfo/Asia/Shanghai /usr/share/zoneinfo/Asia/Shanghai
    ENV TZ Asia/Shanghai
    
    WORKDIR /app
    COPY --from=builder /app/order /app/order
    COPY --from=builder /app/etc /app/etc
    
    EXPOSE 9000
    
    CMD ["./order", "-f", "etc/order.yaml"]
    

    这个情况下 RUN go build -ldflags="-s -w" -o /app/order service/order/api/order.go 最后的那个路径是不对的,需要手动修正

    通常情况下,每个微服务一个Dockerfile,单独build镜像,build context就是该服务整个目录。而go build 不要指定输入文件的。 所以RUN go build -ldflags="-s -w" -o /app/order 这样就够了

    也就是说截图中画圈的完全可以去掉

    Screenshots image

    Environments (please complete the following information):

    • OS: mac OS
    • go-zero version 1.3.3
    • goctl version 1.3.3
    stale need-more-discussion 
    opened by dfang 18
  • Welcome to communicate in English if possible. / 如有可能欢迎大家使用英语交流

    Welcome to communicate in English if possible. / 如有可能欢迎大家使用英语交流

    Hi, dear all

    It would be gratefull if you guys could communicate with each oher in English. Thus, we could have more people around the world to join this project in the near future. Thanks again for your hard working and contribution to the open source community!

    help wanted stale 
    opened by cyouraku 17
  • 使用durationLogger打印日志,崩溃

    使用durationLogger打印日志,崩溃

    部分调用栈信息如下:
    at /usr/local/go/src/runtime/signal_unix.go:846 7 0x0000000000437a4b in runtime.fatalpanic at /usr/local/go/src/runtime/panic.go:1216 8 0x00000000004373b0 in runtime.gopanic at /usr/local/go/src/runtime/panic.go:1064 9 0x000000000044d013 in runtime.panicmem at /usr/local/go/src/runtime/panic.go:212 10 0x000000000044d013 in runtime.sigpanic at /usr/local/go/src/runtime/signal_unix.go:720 11 0x00000000005e7ee6 in log/syslog.(*Writer).Write at /usr/local/go/src/log/syslog/syslog.go:175 12 0x000000000051c6ab in encoding/json.(*Encoder).Encode at /usr/local/go/src/encoding/json/stream.go:231 13 0x00000000005eb938 in github.com/tal-tech/go-zero/core/logx.outputJson at /root/go/pkg/mod/github.com/tal-tech/[email protected]/core/logx/logs.go:380 14 0x00000000005e9eab in github.com/tal-tech/go-zero/core/logx.(*durationLogger).write at /root/go/pkg/mod/github.com/tal-tech/[email protected]/core/logx/durationlogger.go:66 15 0x00000000005e9a75 in github.com/tal-tech/go-zero/core/logx.(*durationLogger).Infof at /root/go/pkg/mod/github.com/tal-tech/[email protected]090637-a7ec5f0cf7d5/core/logx/durationlogger.go:41

    question stale 
    opened by wangyanglong 17
  • API return 不支持除普通结构体、数组(向前兼容,后续考虑废弃)外的其他数据类型作为响应体

    API return 不支持除普通结构体、数组(向前兼容,后续考虑废弃)外的其他数据类型作为响应体

    请问,为什么会考虑废弃数组?

    如果废弃的话,根据 https://go-zero.dev/cn/template.html 来实现统一格式的body相应,则那么无法支持 Data 为数组的情况,如下:

    {
      "code": 0,
      "msg": "OK",
      "data": [{},{}]
    }
    

    你们是否会再考虑考虑?

    feature 
    opened by veezhang 13
  • goctl model mysql不能生成代码

    goctl model mysql不能生成代码

    1. 最新版位v1.1.7, 但go get goctl是v1.1.6
    2. 使用workbench生成sql,其中包含三个表, 总是提示错误 goctl model mysql ddl -src="./*.sql" -dir="./sql/model" error: syntax error at position 461 near 'drop
    3. 只有把包含三个table的sql文件,删的只剩一个table才能创建成功。
    4. https://github.com/jackluo2012/datacenter/blob/main/sql.sql 这个也是使用的go-zero, 也不能生成代码, 同样使用v1.1.6
    opened by william-best 13
  • go mod tidy error:module declares its path as: github.com/zeromicro/go-zero but was required as: github.com/tal-tech/go-zero

    go mod tidy error:module declares its path as: github.com/zeromicro/go-zero but was required as: github.com/tal-tech/go-zero

    Follow the steps on the official website,When creating a new service,run "go mod tidy"Tips:

    go: go-zero-test1/test1 imports
            github.com/tal-tech/go-zero/core/conf: github.com/tal-tech/[email protected]: parsing go.mod:
            module declares its path as: github.com/zeromicro/go-zero
                    but was required as: github.com/tal-tech/go-zero
    

    github.com/tal-tech/go-zero/core/conf/config.go Code of

    import (
    	"fmt"
    	"io/ioutil"
    	"log"
    	"os"
    	"path"
    	"github.com/zeromicro/go-zero/core/mapping"
    )
    

    Change the model so that it can run

    module go-zero
    go 1.16
    require github.com/tal-tech/go-zero v1.1.4
    

    我英语实在不好,基本都是机翻译用汉语再说一下

    按照官网的步骤新建一个单体服务运行go mod tidy的时候提示:

    go: go-zero-test1/test1 imports
            github.com/tal-tech/go-zero/core/conf: github.com/tal-tech/[email protected]: parsing go.mod:
            module declares its path as: github.com/zeromicro/go-zero
                    but was required as: github.com/tal-tech/go-zero
    

    我看到github.com/tal-tech/go-zero/core/conf/config.go的代码

    import (
    	"fmt"
    	"io/ioutil"
    	"log"
    	"os"
    	"path"
    
    	"github.com/zeromicro/go-zero/core/mapping"
    )
    

    但是把go.mod改为

    module go-zero
    
    go 1.16
    
    require github.com/tal-tech/go-zero v1.1.4
    

    就可以成功。

    默认下载的时 v1.3.0版本

    opened by Apa7-zero 12
  • 使用了zrpc client的服务,在收到SIGTERM信号后为什么也需要走gracefulStop方法?以及gracefulStop方法的实现是否不太合理?

    使用了zrpc client的服务,在收到SIGTERM信号后为什么也需要走gracefulStop方法?以及gracefulStop方法的实现是否不太合理?

    按我理解,zrpc server端在收到SIGTERM信号时,确实需要走gracefulStop方法安全退出 但由于client.go和server.go同在package zrpc下,所以同样会调用到core/proc的init()方法,同样会监听信号。这里是不是稍微不太合理?

    image

    而且gracefulStop()方法在实现上,貌似也有点问题:

    func gracefulStop(signals chan os.Signal) {
    	signal.Stop(signals)
    
    	logx.Info("Got signal SIGTERM, shutting down...")
    	wrapUpListeners.notifyListeners()
    
    	time.Sleep(wrapUpTime)
    	shutdownListeners.notifyListeners()
    
    	time.Sleep(delayTimeBeforeForceQuit - wrapUpTime)
    	logx.Infof("Still alive after %v, going to force kill the process...", delayTimeBeforeForceQuit)
    	syscall.Kill(syscall.Getpid(), syscall.SIGTERM)
    }
    

    这里看起来是,收到SIGTERM之后,会关闭所有的listener,然后sleep几秒,然后再给自己发一个SIGTERM 所以理论上这个方法执行结束之前,程序都不会正式退出 但sleep几秒之后,日志中却提示still alive,给人的感觉就是程序异常了,没有正常退出 这里是不是不太合理?

    question stale 
    opened by SgtDaJim 11
  • rpc error: code = Canceled desc = context canceled

    rpc error: code = Canceled desc = context canceled

    对shorturl示例程序进行wrk压力测试中发现,只要连接数较大(-c连接数大于-t线程数的10倍以上,如-t10 -c100)时,gRPC服务大概率就会出现不稳定的情况,开始出现错误,如下(在两台独立的电脑上部署测试,可以复现):

    {"@timestamp":"2020-12-15T15:09:57.967+08","level":"info","duration":"250.8ms","content":"fail - discov:/localhost:2379/transform.rpc/transform.transformer/expand - shorten:"8415a8" - rpc error: code = Canceled desc = context canceled","trace":"1380b2aefad30c00","span":"0.1"}

    同时日志会记录503失败:

    {"@timestamp":"2020-12-15T15:09:57.974+08","level":"error","content":"loghandler.go:135 503 - /expand?shorten=8415a8 - [::1]:50281 - - 257.6ms\nGET /expand?shorten=8415a8 HTTP/1.1\r\nHost: localhost:8888\r\n\r\n","trace":"1380b2aefad30c00","span":"0"}

    经过代码调试,此报错由grpc框架接收端抛出,是在等待接收数据包时,context被关闭,导致请求被cancel的情况,但没有跟踪到context被关闭的具体原因。试过设置gRPC的Timeout,但没有作用。

    另外,目前在Mac Pro(CPU 2.6GHz 六核 i7,OS 版本 10.15.7)上 wrk -t10 -c80 能跑出最高的QPS是1万左右,和示例程序的Benchmark 3万相差甚远,不知道是否还需要额外做和设置。

    所用的Go版本是1.15.6,依赖包是 github.com/tal-tech/go-zero v1.0.29 (默认的1.0.16版本也有此问题) google.golang.org/grpc v1.29.1 google.golang.org/protobuf v1.25.0 (默认的github.com/golang/protobuf v1.4.2也有此问题)

    opened by caseylai 11
  • defer will not run correctly

    defer will not run correctly

    func main() {
    	flag.Parse()
    
    	var c config.Config
    	conf.MustLoad(*configFile, &c)
    	ctx := svc.NewServiceContext(c)
    	svr := server.NewMyrpcServer(ctx)
    
    	s := zrpc.MustNewServer(c.RpcServerConf, func(grpcServer *grpc.Server) {
    		myrpc.RegisterMyrpcServer(grpcServer, svr)
    
    		if c.Mode == service.DevMode || c.Mode == service.TestMode {
    			reflection.Register(grpcServer)
    		}
    	})
    	defer s.Stop() // this line
            defer fmt.Println("stop") // and this line
    
    	fmt.Printf("Starting rpc server at %s...\n", c.ListenOn)
    	s.Start()
    }
    

    when I close the program, program has no output "stop". why ?

    opened by MasterJoyHunan 0
  • how to set default value which field is binary type?

    how to set default value which field is binary type?

    i have a table

    CREATE TABLE `policy` (
        `id` BINARY(16) NOT NULL DEFAULT (UUID_TO_BIN(UUID())),
        `policy` VARCHAR(255) NOT NULL DEFAULT "",
        PRIMARY KEY (`id`)
    ) ENGINE=InnoDB  DEFAULT CHARSET=utf8mb4 ;
    

    i generate code by `goctl model mysql ddl -src ./policy.sql -dir . -c'

    i wish the generated code insert new rowitem without id, because it has default value

    how can i do it?

    opened by loyalpartner 0
  • Whether a Task service is required?

    Whether a Task service is required?

    Is your feature request related to a problem? Please describe. Similar to beego's task

    Describe the solution you'd like Enables lightweight timed task scheduling

    opened by songangweb 0
  • Support Server-Sent-Events?

    Support Server-Sent-Events?

    Is your feature request related to a problem? Please describe. Go-zero unsupport SSE without set global config Timeout to 0. When i want to use SSE, must to set Header {"upgrade": "websocket"}. But chrome unsupport change header Upgrade

    Describe the solution you'd like A clear and concise description of what you want to happen. Add a new header to identify the request SSE.

    Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered. Add new config for SSE. If set SSE config, skip timeoutHandler

    Additional context Add any other context or screenshots about the feature request here. scheme 1 PR: https://github.com/zeromicro/go-zero/pull/2028

    scheme 2 image

    opened by icecoffee531 7
Releases(tools/goctl/v1.3.8)
  • v1.3.4(Jun 3, 2022)

    Features and Updates:

    • support using third-party logging libs with logx
    • support LogField with methods Infow, Errorw and Sloww in logx, like logx.Infow(msg, logx.Field(key1, val1), logx.Field(key2, val2))
    • logx now supports terminal colors with Encoding: plain
    • support toml config files
    • support client stream interceptors for gRPC
    • set default connection idle time to 5 minutes for gRPC servers
    • enable health check in gRPC servers
    • even more clear trace info for redis, sql and mongodb
    • removed deprecated usages from dependencies
    • update go version to 1.16, because of security reasons in k8s.io/client-go
    • minor bug fixes and improvements

    Change logs

    • docs: update readme by @kevwan in https://github.com/zeromicro/go-zero/pull/1849
    • test: add more tests by @kevwan in https://github.com/zeromicro/go-zero/pull/1856
    • fix typo by @sixwaaaay in https://github.com/zeromicro/go-zero/pull/1857
    • feat: add fields with logx methods, support using third party logging libs. by @kevwan in https://github.com/zeromicro/go-zero/pull/1847
    • chore: use time.Now() instead of timex.Time() because go optimized it by @kevwan in https://github.com/zeromicro/go-zero/pull/1860
    • test: add codecov by @kevwan in https://github.com/zeromicro/go-zero/pull/1861
    • test: add codecov by @kevwan in https://github.com/zeromicro/go-zero/pull/1863
    • chore: refine tests by @kevwan in https://github.com/zeromicro/go-zero/pull/1864
    • fix time, duration, slice types on logx.Field by @kevwan in https://github.com/zeromicro/go-zero/pull/1868
    • add conf documents by @kevwan in https://github.com/zeromicro/go-zero/pull/1869
    • chore: fix deprecated usages by @kevwan in https://github.com/zeromicro/go-zero/pull/1871
    • feat: Replace cli to cobra by @anqiansong in https://github.com/zeromicro/go-zero/pull/1855
    • feat: logx with color by @kevwan in https://github.com/zeromicro/go-zero/pull/1872
    • chore: update some logs by @kevwan in https://github.com/zeromicro/go-zero/pull/1875
    • chore: improve codecov by @kevwan in https://github.com/zeromicro/go-zero/pull/1878
    • fix:tools/goctl/rpc/generator/template_test.go file has wrong parameters by @wangzeping722 in https://github.com/zeromicro/go-zero/pull/1882
    • fix ts template by @SeigeC in https://github.com/zeromicro/go-zero/pull/1879
    • fix: Code generation by @anqiansong in https://github.com/zeromicro/go-zero/pull/1897
    • feat: Add goctl quickstart by @anqiansong in https://github.com/zeromicro/go-zero/pull/1889
    • refactor: refactor trace in redis & sql & mongo by @chenquan in https://github.com/zeromicro/go-zero/pull/1865
    • chore: coding style for quickstart by @kevwan in https://github.com/zeromicro/go-zero/pull/1902
    • feat: add toml config by @kevwan in https://github.com/zeromicro/go-zero/pull/1899
    • chore: use goproxy properly by @kevwan in https://github.com/zeromicro/go-zero/pull/1903
    • chore: use get for quickstart, plain logs for easy understanding by @kevwan in https://github.com/zeromicro/go-zero/pull/1905
    • feat: support WithStreamClientInterceptor for zrpc clients by @kevwan in https://github.com/zeromicro/go-zero/pull/1907
    • fix: Fix process blocking problem during check by @anqiansong in https://github.com/zeromicro/go-zero/pull/1911
    • chore: update k8s.io/client-go for security reason, go is upgrade to 1.16 by @kevwan in https://github.com/zeromicro/go-zero/pull/1912
    • feat: set default connection idle time for grpc servers, and health check supported by @kevwan in https://github.com/zeromicro/go-zero/pull/1922
    • fix: Useless delete cache logic in update by @anqiansong in https://github.com/zeromicro/go-zero/pull/1923
    • fix: Support built-in shorthand flags by @anqiansong in https://github.com/zeromicro/go-zero/pull/1925
    • feat: update docker alpine package mirror by @kevwan in https://github.com/zeromicro/go-zero/pull/1924
    • chore: add release action to auto build binaries by @chenquan in https://github.com/zeromicro/go-zero/pull/1884
    • chore(action): simplified release configuration by @chenquan in https://github.com/zeromicro/go-zero/pull/1935
    • core/mr:a little optimization for collector initialization in ForEach function by @notrynosuccess in https://github.com/zeromicro/go-zero/pull/1937
    • code simplification. by @lizhichao in https://github.com/zeromicro/go-zero/pull/1939
    • chore: refine docker for better compatible with package main by @kevwan in https://github.com/zeromicro/go-zero/pull/1944
    • Delete duplicated crash recover logic. by @kunyu in https://github.com/zeromicro/go-zero/pull/1950
    • chore: update roadmap by @kevwan in https://github.com/zeromicro/go-zero/pull/1948
    • fix: panic on convert to string on fillSliceFromString() by @cjf8134 in https://github.com/zeromicro/go-zero/pull/1951
    • chore: refactoring mapping string to slice by @kevwan in https://github.com/zeromicro/go-zero/pull/1959

    New Contributors

    • @sixwaaaay made their first contribution in https://github.com/zeromicro/go-zero/pull/1857
    • @wangzeping722 made their first contribution in https://github.com/zeromicro/go-zero/pull/1882
    • @SeigeC made their first contribution in https://github.com/zeromicro/go-zero/pull/1879
    • @notrynosuccess made their first contribution in https://github.com/zeromicro/go-zero/pull/1937
    • @kunyu made their first contribution in https://github.com/zeromicro/go-zero/pull/1950
    • @cjf8134 made their first contribution in https://github.com/zeromicro/go-zero/pull/1951

    Full Changelog: https://github.com/zeromicro/go-zero/compare/v1.3.3...v1.3.4

    Source code(tar.gz)
    Source code(zip)
  • v1.3.3(May 1, 2022)

    1. add mon and monc packages to use official driver for mongodb
    2. add httpc.Do and httpc.Service.Do to make requests from defined structs
    3. ignore timeout settings on websocket connections
    4. support sub-domains for CORS
    5. tracing span added in redis, sql and mongodb calls
    6. upgrade gRPC to 1.46, removed the deprecated usage of grpc.WithBalancerName
    7. bug fixes and minor improvements
    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.3.5(May 1, 2022)

    Features

    • Support nested importing in API files
    • Add go-grpc_opt, go_opt flag for cmd goctl rpc new on #1769 by @chowyu12
    • Support go work multi-module on #1800 by @fynxiu
    • Minor improvements

    Fix

    • Fix nil pointer if group not exists on #1773 by @anqiansong
    • Fix model code generation crash bug on #17777 by @600ML
    • Fix typo in file api/new/api.tpl on #1788 by @fynxiu
    • Fix generated files without name from empty API file on #1811 by @anqiansong
    • Other bug fixes
    Source code(tar.gz)
    Source code(zip)
  • v1.3.2(Apr 3, 2022)

    • support cgroups v2 for CPU statistics
    • add httpc package
      • enable OpenTelemetry and circuit breaker for HTTP client calls
      • make parsing HTTP responses easy with httpc.Parse(...)
    • support - in tags of model, allows ignoring the corresponding fields on SQL queries
    • support :N dynamic parameters in Oracle database
    • support getset redis command
    • SetBit in redis now returns the original value
    • disable re-entrance for RedisLock
    • minor improvements and bug fixes
    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.3.4(Apr 3, 2022)

    What's Changed

    • support to set timeout in api on #1713 by jiang4869
    • support api format with reader input on #1722 by fynxiu
    • support -base to specify image for goctl docker on #1668 by kevwan
    • add --verbose flag for goctl env and goctl rpc on #1686 by anqiansong
    • make directories if not exists while zrpc code generation on #1659 by anqiansong
    • optimize cache model code generation on #1672 by Mikaelemmmm
    • optimize model tag on #1663 by mervin0502
    • remove command goctl rpc proto on #1665 by anqiansong

    New Contributors

    • @mervin0502 made their first contribution in https://github.com/zeromicro/go-zero/pull/1663
    • @wubenqi made their first contribution in https://github.com/zeromicro/go-zero/pull/1693
    • @aimuz made their first contribution in https://github.com/zeromicro/go-zero/pull/1702
    • @jiang4869 made their first contribution in https://github.com/zeromicro/go-zero/pull/1713

    Full Changelog: https://github.com/zeromicro/go-zero/compare/tools/goctl/v1.3.3...tools/goctl/v1.3.4

    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.3.3(Mar 17, 2022)

    Features

    • Add ServiceAccount on goctl kuke on #1543 by @Mikaelemmmm
    • Support context in sql model generation on #1551 by @kevwan
    • Add goctl env on #1557 by @anqiansong
    • Support pg serial type on #1563 by @kurimi1
    • Support absoulutely import path on #1569 by @fynxiu
    • Support Dart v2 on #1603 by @fynxiu

    Fixes

    • Use struct pointer on #1538 by @mlr3000
    • Fix integer overflow while build goctl on arch 386 on #1582 by @anqiansong
    • Support form tag in dart on #1596 by @fynxiu
    • Fix goctl rpc code genertion on #1624 by @anqiansong
    • Fix kotlin code generion error on #1632 by @soasurs
    • Fix context missing in sql model on #1642 by @xybingbing
    Source code(tar.gz)
    Source code(zip)
  • v1.3.1(Mar 1, 2022)

    What's Changed

    • update go-redis to v8, support ctx in redis methods, OpenTelemetry enabled by @kevwan in https://github.com/zeromicro/go-zero/pull/1507
    • support ctx in sqlx/sqlc, OpenTelemetry enabled by @kevwan in https://github.com/zeromicro/go-zero/pull/1535
    • support ctx in Cache, OpenTelemetry enabled by @chenquan in https://github.com/zeromicro/go-zero/pull/1518
    • log 404 requests with traceid by @kevwan in https://github.com/zeromicro/go-zero/pull/1554
    • minor bug fixes and improvements

    New Contributors

    • @mlr3000 made their first contribution in https://github.com/zeromicro/go-zero/pull/1538
    • @fynxiu made their first contribution in https://github.com/zeromicro/go-zero/pull/1569
    • @x1nchen made their first contribution in https://github.com/zeromicro/go-zero/pull/1589

    Full Changelog: https://github.com/zeromicro/go-zero/compare/v1.3.0...v1.3.1

    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.3.2(Feb 14, 2022)

    1. support goctl completion to enable zsh/bash completion type goctl and press TAB key to show completion, like below: image
    2. bug fixes and minor improvements
    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.3.0(Feb 10, 2022)

    What's Changed

    • docs: update tal-tech to zeromico in docs by @kevwan in https://github.com/zeromicro/go-zero/pull/1498
    • fix: goctl not compile on windows by @kevwan in https://github.com/zeromicro/go-zero/pull/1500
    • chore: update command comment by @kevwan in https://github.com/zeromicro/go-zero/pull/1501
    • fix typo: goctl protoc usage by @anqiansong in https://github.com/zeromicro/go-zero/pull/1502
    • ci: add test for win by @kevwan in https://github.com/zeromicro/go-zero/pull/1503
    • test: change fuzz tests by @kevwan in https://github.com/zeromicro/go-zero/pull/1504
    • feature: Add goctl completion by @anqiansong in https://github.com/zeromicro/go-zero/pull/1505
    • fixes typo by @anqiansong in https://github.com/zeromicro/go-zero/pull/1511
    • feat: update go-redis to v8, support ctx in redis methods by @kevwan in https://github.com/zeromicro/go-zero/pull/1507
    • chore: make error clearer by @chenquan in https://github.com/zeromicro/go-zero/pull/1514
    • chore: optimize yaml unmarshaler by @chenquan in https://github.com/zeromicro/go-zero/pull/1513
    • refactor: refactor yaml unmarshaler by @kevwan in https://github.com/zeromicro/go-zero/pull/1517

    Full Changelog: https://github.com/zeromicro/go-zero/compare/v1.3.0...tools/goctl/v1.3.0

    Source code(tar.gz)
    Source code(zip)
  • v1.3.0(Feb 1, 2022)

    Framework

    • rename module from tal-tech to zeromicro by @kevwan in https://github.com/zeromicro/go-zero/pull/1413
      • upgrade from earlier versions:
        1. update goctl: go install github.com/zeromicro/go-zero/tools/[email protected]
        2. migrate command: goctl migrate --verbose --version v1.3.0
    • support re-entrance in periodlimit by @kevwan in https://github.com/zeromicro/go-zero/pull/1428
    • support panic handling in mapreduce (core/mr package) by @kevwan in https://github.com/zeromicro/go-zero/pull/1433
    • support the ltrim command of redis by @shenbaise9527 in https://github.com/zeromicro/go-zero/pull/1443
    • implement console plain output for debug logs by @kevwan in https://github.com/zeromicro/go-zero/pull/1456
    • optimize string search with Aho–Corasick algorithm by @kevwan in https://github.com/zeromicro/go-zero/pull/1476
    • minor improvements and bug fixes

    goctl

    • add migrate subcommand to upgrade go-zero from earlier versions by @anqiansong in https://github.com/zeromicro/go-zero/pull/1419
    • fix goctl pg model generation without tag by @SpectatorNan in https://github.com/zeromicro/go-zero/pull/1407
    • support rpc protoc subcommand to use installed protoc by @anqiansong in https://github.com/zeromicro/go-zero/pull/1251
    • support global parameters in templates by @anqiansong in https://github.com/zeromicro/go-zero/pull/1458
    • support JwtTransition in API files by @anqiansong in https://github.com/zeromicro/go-zero/pull/1460
    • support same handler name in different API groups by @anqiansong in https://github.com/zeromicro/go-zero/pull/1478
    • minor improvements and bug fixes

    New Contributors

    • @SpectatorNan made their first contribution in https://github.com/zeromicro/go-zero/pull/1407
    • @letian-jiang made their first contribution in https://github.com/zeromicro/go-zero/pull/1454
    • @Lisanaaa made their first contribution in https://github.com/zeromicro/go-zero/pull/1475

    Full Changelog: https://github.com/zeromicro/go-zero/compare/v1.2.5...v1.3.0

    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.3.1(Feb 1, 2022)

    goctl

    • add migrate subcommand to upgrade go-zero from earlier versions by @anqiansong in #1419
      • use it like: goctl migrate --version v1.3.0 --verbose
    • fix goctl pg model generation without tag by @SpectatorNan in #1407
    • support rpc protoc subcommand to use installed protoc by @anqiansong in #1251
    • support global parameters in templates by @anqiansong in #1458
    • support JwtTransition in API files by @anqiansong in #1460
    • support same handler name in different API groups by @anqiansong in #1478
    • minor improvements and bug fixes
    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.3.0-beta1(Jan 26, 2022)

    What's Changed

    • refactor file|path by @anqiansong in https://github.com/zeromicro/go-zero/pull/1409
    • chore: update go-zero to v1.2.5 by @kevwan in https://github.com/zeromicro/go-zero/pull/1410
    • feat: rename module from tal-tech to zeromicro by @kevwan in https://github.com/zeromicro/go-zero/pull/1413
    • chore: refactor rest/timeouthandler by @kevwan in https://github.com/zeromicro/go-zero/pull/1415
    • docs: update install readme by @kevwan in https://github.com/zeromicro/go-zero/pull/1417
    • feat: Add migrate by @anqiansong in https://github.com/zeromicro/go-zero/pull/1419
    • Fix goctl pg model generation without tag by @SpectatorNan in https://github.com/zeromicro/go-zero/pull/1407
    • update docs by @kevwan in https://github.com/zeromicro/go-zero/pull/1421
    • fix: golint issue by @kevwan in https://github.com/zeromicro/go-zero/pull/1423
    • docs: add go-zero users by @kevwan in https://github.com/zeromicro/go-zero/pull/1424
    • docs: add go-zero users by @kevwan in https://github.com/zeromicro/go-zero/pull/1425
    • chore: refactor periodlimit by @kevwan in https://github.com/zeromicro/go-zero/pull/1428
    • fix: mr goroutine leak on context deadline by @kevwan in https://github.com/zeromicro/go-zero/pull/1433
    • remove unnecessary drain, fix data race by @kevwan in https://github.com/zeromicro/go-zero/pull/1435
    • chore: fix typo by @kevwan in https://github.com/zeromicro/go-zero/pull/1437
    • Feature rpc protoc by @anqiansong in https://github.com/zeromicro/go-zero/pull/1251
    • ci: add translator action by @kevwan in https://github.com/zeromicro/go-zero/pull/1441
    • chore: upgrade dependencies by @kevwan in https://github.com/zeromicro/go-zero/pull/1444
    • feat: support the ltrim command of redis by @shenbaise9527 in https://github.com/zeromicro/go-zero/pull/1443
    • chore: remove jwt deprecated by @kevwan in https://github.com/zeromicro/go-zero/pull/1452
    • chore: check interface satisfaction w/o allocating new variable by @letian-jiang in https://github.com/zeromicro/go-zero/pull/1454
    • feat: implement console plain output for debug logs by @kevwan in https://github.com/zeromicro/go-zero/pull/1456
    • Fix/issue#1447 by @anqiansong in https://github.com/zeromicro/go-zero/pull/1458
    • patch: save missing templates to disk by @anqiansong in https://github.com/zeromicro/go-zero/pull/1463
    • Fix/issue#1289 by @anqiansong in https://github.com/zeromicro/go-zero/pull/1460
    • chore: update unauthorized callback calling order by @kevwan in https://github.com/zeromicro/go-zero/pull/1469
    • docs: add go-zero users by @kevwan in https://github.com/zeromicro/go-zero/pull/1473
    • Polish the words in readme.md by @Lisanaaa in https://github.com/zeromicro/go-zero/pull/1475
    • chore: optimize string search with Aho–Corasick algorithm by @kevwan in https://github.com/zeromicro/go-zero/pull/1476
    • fix #1468 by @anqiansong in https://github.com/zeromicro/go-zero/pull/1478
    • Feature/trie ac automation by @kevwan in https://github.com/zeromicro/go-zero/pull/1479
    • refactor: rename from tal-tech to zeromicro for goctl by @kevwan in https://github.com/zeromicro/go-zero/pull/1481
    • chore: update go version for goctl by @kevwan in https://github.com/zeromicro/go-zero/pull/1484
    • patch: goctl migrate by @anqiansong in https://github.com/zeromicro/go-zero/pull/1485
    • chore: update warning message by @kevwan in https://github.com/zeromicro/go-zero/pull/1487

    New Contributors

    • @SpectatorNan made their first contribution in https://github.com/zeromicro/go-zero/pull/1407
    • @letian-jiang made their first contribution in https://github.com/zeromicro/go-zero/pull/1454
    • @Lisanaaa made their first contribution in https://github.com/zeromicro/go-zero/pull/1475

    Full Changelog: https://github.com/zeromicro/go-zero/compare/v1.2.5...tools/goctl/v1.3.0-beta1

    Source code(tar.gz)
    Source code(zip)
  • v1.3.0-beta(Jan 25, 2022)

    What's Changed

    • refactor file|path by @anqiansong in https://github.com/zeromicro/go-zero/pull/1409
    • chore: update go-zero to v1.2.5 by @kevwan in https://github.com/zeromicro/go-zero/pull/1410
    • feat: rename module from tal-tech to zeromicro by @kevwan in https://github.com/zeromicro/go-zero/pull/1413
    • chore: refactor rest/timeouthandler by @kevwan in https://github.com/zeromicro/go-zero/pull/1415
    • docs: update install readme by @kevwan in https://github.com/zeromicro/go-zero/pull/1417
    • feat: Add migrate by @anqiansong in https://github.com/zeromicro/go-zero/pull/1419
    • Fix goctl pg model generation without tag by @SpectatorNan in https://github.com/zeromicro/go-zero/pull/1407
    • update docs by @kevwan in https://github.com/zeromicro/go-zero/pull/1421
    • fix: golint issue by @kevwan in https://github.com/zeromicro/go-zero/pull/1423
    • docs: add go-zero users by @kevwan in https://github.com/zeromicro/go-zero/pull/1424
    • docs: add go-zero users by @kevwan in https://github.com/zeromicro/go-zero/pull/1425
    • chore: refactor periodlimit by @kevwan in https://github.com/zeromicro/go-zero/pull/1428
    • fix: mr goroutine leak on context deadline by @kevwan in https://github.com/zeromicro/go-zero/pull/1433
    • remove unnecessary drain, fix data race by @kevwan in https://github.com/zeromicro/go-zero/pull/1435
    • chore: fix typo by @kevwan in https://github.com/zeromicro/go-zero/pull/1437
    • Feature rpc protoc by @anqiansong in https://github.com/zeromicro/go-zero/pull/1251
    • ci: add translator action by @kevwan in https://github.com/zeromicro/go-zero/pull/1441
    • chore: upgrade dependencies by @kevwan in https://github.com/zeromicro/go-zero/pull/1444
    • feat: support the ltrim command of redis by @shenbaise9527 in https://github.com/zeromicro/go-zero/pull/1443
    • chore: remove jwt deprecated by @kevwan in https://github.com/zeromicro/go-zero/pull/1452
    • chore: check interface satisfaction w/o allocating new variable by @letian-jiang in https://github.com/zeromicro/go-zero/pull/1454
    • feat: implement console plain output for debug logs by @kevwan in https://github.com/zeromicro/go-zero/pull/1456
    • Fix/issue#1447 by @anqiansong in https://github.com/zeromicro/go-zero/pull/1458
    • patch: save missing templates to disk by @anqiansong in https://github.com/zeromicro/go-zero/pull/1463
    • Fix/issue#1289 by @anqiansong in https://github.com/zeromicro/go-zero/pull/1460
    • chore: update unauthorized callback calling order by @kevwan in https://github.com/zeromicro/go-zero/pull/1469
    • docs: add go-zero users by @kevwan in https://github.com/zeromicro/go-zero/pull/1473
    • Polish the words in readme.md by @Lisanaaa in https://github.com/zeromicro/go-zero/pull/1475
    • chore: optimize string search with Aho–Corasick algorithm by @kevwan in https://github.com/zeromicro/go-zero/pull/1476
    • fix #1468 by @anqiansong in https://github.com/zeromicro/go-zero/pull/1478
    • Feature/trie ac automation by @kevwan in https://github.com/zeromicro/go-zero/pull/1479

    New Contributors

    • @SpectatorNan made their first contribution in https://github.com/zeromicro/go-zero/pull/1407
    • @letian-jiang made their first contribution in https://github.com/zeromicro/go-zero/pull/1454
    • @Lisanaaa made their first contribution in https://github.com/zeromicro/go-zero/pull/1475

    Full Changelog: https://github.com/zeromicro/go-zero/compare/v1.2.5...v1.3.0-beta

    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.2.6(Jan 8, 2022)

  • v1.3.0-alpha(Jan 5, 2022)

  • tools/goctl/v1.2.5(Jan 3, 2022)

    • fix: goctl upgrade issue on windows by @anqiansong in #1307
    • fix: goctl not working for / path by @anqiansong in #1321
    • support postgresql data type bytea in model generation by @yangkequn in #1314
    • add goctl bug to report bugs conveniently by @anqiansong in #1332
    • keep the golang keywords in model tags by @qwxingzhe in #1369
    • support bit byte for mysql code generation by @anqiansong in #1380
    • add --remote for using remote git repo as goctl template by @anqiansong in #1387
    • fix --home bugs by @anqiansong in #1382
    Source code(tar.gz)
    Source code(zip)
  • v1.2.5(Jan 3, 2022)

    framework:

    • fix: load balancer for gRPC might crash on 32-bit cpu by @BYT0723 in https://github.com/zeromicro/go-zero/pull/1298
    • fix: concurrent problems for logx.WithContext and logx.WithDuration by @kevwan in https://github.com/zeromicro/go-zero/pull/1317
    • add redis.Decr, redis.Decrby, redis.Lindex methods by @CrazyZard in https://github.com/zeromicro/go-zero/pull/1325
    • support adding custom cache to mongoc and sqlc by @MarkJoyMa in https://github.com/zeromicro/go-zero/pull/1313
    • set the status code for client closed requests as 499 by @kevwan in https://github.com/zeromicro/go-zero/pull/1350
    • support context in MapReduce by @kevwan in https://github.com/zeromicro/go-zero/pull/1368
    • support array in default and options tags for unmarshal methods by @kevwan in https://github.com/zeromicro/go-zero/pull/1386
    • httpx.SetErrorHandler now works for http timeout error by @kevwan in https://github.com/zeromicro/go-zero/pull/1389
    • implement fx.NoneMatch, fx.First, fx.Last by @kevwan in https://github.com/zeromicro/go-zero/pull/1402
    • support TLS for etcd client by @kevwan in https://github.com/zeromicro/go-zero/pull/1390

    goctl

    • fix: goctl upgrade issue on windows by @anqiansong in https://github.com/zeromicro/go-zero/pull/1307
    • fix: goctl not working for / path by @anqiansong in https://github.com/zeromicro/go-zero/pull/1321
    • support postgresql data type bytea in model generation by @yangkequn in https://github.com/zeromicro/go-zero/pull/1314
    • add goctl bug to report bugs conveniently by @anqiansong in https://github.com/zeromicro/go-zero/pull/1332
    • keep the golang keywords in model tags by @qwxingzhe in https://github.com/zeromicro/go-zero/pull/1369
    • support bit byte for mysql code generation by @anqiansong in https://github.com/zeromicro/go-zero/pull/1380
    • add --remote for using remote git repo as goctl template by @anqiansong in https://github.com/zeromicro/go-zero/pull/1387
    • fix --home bugs by @anqiansong in https://github.com/zeromicro/go-zero/pull/1382

    New Contributors

    • @BYT0723 made their first contribution in https://github.com/zeromicro/go-zero/pull/1298
    • @CrazyZard made their first contribution in https://github.com/zeromicro/go-zero/pull/1325
    • @yangkequn made their first contribution in https://github.com/zeromicro/go-zero/pull/1314
    • @MarkJoyMa made their first contribution in https://github.com/zeromicro/go-zero/pull/1313
    • @lizhichao made their first contribution in https://github.com/zeromicro/go-zero/pull/1343
    • @charliecen made their first contribution in https://github.com/zeromicro/go-zero/pull/1359
    • @richardJiang made their first contribution in https://github.com/zeromicro/go-zero/pull/1356
    • @peasfarmer made their first contribution in https://github.com/zeromicro/go-zero/pull/1366
    • @qwxingzhe made their first contribution in https://github.com/zeromicro/go-zero/pull/1369
    • @Leizhengzi made their first contribution in https://github.com/zeromicro/go-zero/pull/1377
    • @moyrne made their first contribution in https://github.com/zeromicro/go-zero/pull/1388

    Full Changelog: https://github.com/zeromicro/go-zero/compare/v1.2.4...v1.2.5

    Source code(tar.gz)
    Source code(zip)
  • tools/goctl/v1.2.4(Dec 30, 2021)

    1. add goctl bug command to start reporting bug window
    2. support bit type of mysql
    3. support bytea type of postgresql
    4. support / in API routes
    5. bug fixes and minor improvements
    Source code(tar.gz)
    Source code(zip)
  • v1.2.4(Dec 1, 2021)

    framework:

    1. support map in config file
    2. support customizing headers in CORS handler
    3. export zrpc/resolver to let other frameworks to interact with go-zero
    4. minor improvements

    goctl:

    1. fix builderx import problem
    2. support returning primitive types and arrays in API handlers
    3. support prefix directive in API
    4. support root path in API
    5. bug fixes and minor improvements
    Source code(tar.gz)
    Source code(zip)
  • v1.2.3(Nov 16, 2021)

    framework:

    1. support TLS in rest (web framework)
    2. support TLS in zrpc
    3. support TLS for redis connections
    4. support username/password authentication for etcd
    5. support CORS in rest (web framework)
    6. support prefix for group of routes, also supported through prefix in .api files
    7. support individual timeout setting for specific route(s)
    8. support NonBlock dependency checking mode, default to be blocking mode
    9. slow threshold for stat logs now can be set in redis, sqlx, mongo, rest, zrpc
    10. minor bug fixes and improvements

    goctl:

    1. support prefix code generation in .api files
    2. support multiple version templates
    3. optimize the syntax of requests with empty body
    4. fix the issue of grpc client package generation
    5. goctl returns non-zero status code on failure
    6. bug fixes and minor improvements
    Source code(tar.gz)
    Source code(zip)
  • v1.2.2(Oct 12, 2021)

    framework:

    1. Support OpenTelemetry, Trace ID is set in responses with HTTP header X-Trace-Id
    2. AtomicError now accept nil error
    3. Deprecated redis.NewRedis, use redis.New instead

    goctl:

    1. Supported protoc plugin protoc-gen-goctl
    2. Fixed issue #1058
    Source code(tar.gz)
    Source code(zip)
  • v1.2.1(Sep 14, 2021)

    framework:

    1. downgrade k8s.io/client-go to use go 1.15
    2. fix proc.Done issue on windows

    goctl:

    1. fix #1028, remove goctl config subcommand
    2. fix goctl issue on windows for ReadLink not defined
    Source code(tar.gz)
    Source code(zip)
  • v1.2.0(Sep 13, 2021)

    framework:

    1. suported Kubernetes based service discovery, use k8s://namespace/service:port as the RPC Target value. More service discovery solutions can be supported by plugins.
    2. logging arbitary value with json format, use logx.Infov/Errorv/Slowv.
    3. disable stat logs by calling logx.DisableStat().
    4. bug fixes and improvements.

    goctl:

    1. optimize code generation for mongodb without cache
    2. optimize environment check before grpc code generation
    3. optimize naming specification in model
    4. print errors along with the goctl version and details
    5. #915 resolve inline message code generation in grpc
    6. #925, #929 optimize data type conversion for mysql in case NULL column
    7. #968 read the destination path from symbol link
    Source code(tar.gz)
    Source code(zip)
  • v1.1.10(Aug 4, 2021)

  • v1.1.9(Aug 3, 2021)

    Framework:

    1. httpx.Parse(...) now parses http header as well
    2. exits on port already in use
    3. minor bug fixes and improvements

    goctl:

    1. add flag --go_opt for goctl proto to be compatible with github.com/golang/protobuf/[email protected]
    2. replace sql-parser with ddl-parser
    3. support gRPC stream code generation
    4. support postgresql model generation
    5. support mysql data type blob
    6. add flag --home to specify the directory to save the goctl templates
    Source code(tar.gz)
    Source code(zip)
  • v1.1.8(Jun 28, 2021)

    framework:

    1. upgrade gRPC to v1.38.0
    2. upgrade etcd to v3.5.0
    3. add more functions in fx package
    4. support unmarshaling multi-dim slices in mapping package
    5. more clear errors on wrong routes for rest routes
    6. detail sql statements in sql logs
    7. minor bug fixes and improvements

    goctl:

    1. replace cache key with colon
    2. parse comments and documents in .api files to api.Spec
    3. replace new line with empty string for column comment
    4. minor bug fixes and improvements
    Source code(tar.gz)
    Source code(zip)
  • v1.1.7(May 8, 2021)

    framework:

    1. support tls in redis
    2. disable prometheus if not configured in config files
    3. remove contextx.ShrinkDeadline, use context.WithTimeout instead

    goctl:

    1. fix antlr conflicts on installing goctl
    Source code(tar.gz)
    Source code(zip)
Owner
好未来技术
好未来开源
好未来技术
Goal is a toolkit for high productivity web development in Go language in the spirit of Revel Framework that is built around the concept of code generation.

Goal Goal is a set of tools for high productivity web development in Go language. Goal, being mostly inspired by Revel Framework and its discussions,

null 88 Sep 27, 2021
A high productivity, full-stack web framework for the Go language.

Revel Framework A high productivity, full-stack web framework for the Go language. Current Version: 1.0.0 (2020-07-11) Supports go.mod package managem

Revel Framework 12.6k Jun 25, 2022
The web framework for writing faster sites, faster

Gondola The web framework for writing faster sites, faster. Written in Go. View documentation at http://gondolaweb.com. Unless indicated otherwise at

Rainy Cape S.L. 309 Jan 24, 2022
RPC Framework abstraction layer. Provides foundation of the RonyDesc to generate RPC server/client codes.

RonyKit RonyKit provides the abstraction layer for creating a cluster aware API server. By defining separate components for each task, you are almost

Ronak Software Group 3 Feb 21, 2022
Microservice framework following best cloud practices with a focus on productivity.

patron Patron is a framework for creating microservices, originally created by Sotiris Mantzaris (https://github.com/mantzas). This fork is maintained

Beat Labs 96 Jun 21, 2022
Roche is a Code Generator and Web Framework, makes web development super concise with Go, CleanArch

It is still under development, so please do not use it. We plan to release v.1.0.0 in the summer. roche is a web framework optimized for microservice

Riita 15 May 21, 2022
Flamingo Framework and Core Library. Flamingo is a go based framework for pluggable web projects. It is used to build scalable and maintainable (web)applications.

Flamingo Framework Flamingo is a web framework based on Go. It is designed to build pluggable and maintainable web projects. It is production ready, f

Flamingo 302 Jun 17, 2022
based on go lang build WEB development framework for go lang beginners .

based on go lang build WEB development framework for go lang beginners .

zhenfan.yu 1 Oct 31, 2021
Golanger Web Framework is a lightweight framework for writing web applications in Go.

/* Copyright 2013 Golanger.com. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except

golanger 299 Mar 3, 2022
The jin is a simplified version of the gin web framework that can help you quickly understand the core principles of a web framework.

jin About The jin is a simplified version of the gin web framework that can help you quickly understand the core principles of a web framework. If thi

null 8 Dec 27, 2021
An efficient, extensible and easy-to-use RPC framework.

eRPC eRPC is an efficient, extensible and easy-to-use RPC framework. Suitable for RPC, Microservice, Peer-to-Peer, IM, Game and other fields. 简体中文 Ins

henrylee2cn 2.3k Jun 25, 2022
henrylee2cn 1.6k Jun 26, 2022
GoFrame is a modular, powerful, high-performance and enterprise-class application development framework of Golang.

GoFrame English | 简体中文 GoFrame is a modular, powerful, high-performance and enterprise-class application development framework of Golang. If you're a

GoFrame 7.6k Jun 19, 2022
⚡ Rux is an simple and fast web framework. support middleware, compatible http.Handler interface. 简单且快速的 Go web 框架,支持中间件,兼容 http.Handler 接口

Rux Simple and fast web framework for build golang HTTP applications. NOTICE: v1.3.x is not fully compatible with v1.2.x version Fast route match, sup

Gookit 77 Apr 16, 2022
A powerful go web framework for highly scalable and resource efficient web application

webfr A powerful go web framework for highly scalable and resource efficient web application Installation: go get -u github.com/krishpranav/webfr Exa

Krisna Pranav 13 Nov 28, 2021
A powerful go web framework for highly scalable and resource efficient web application

A powerful go web framework for highly scalable and resource efficient web application

null 21 May 25, 2022
gnark is a fast, open-source library for zero-knowledge proof protocols written in Go

gnark gnark is a framework to execute (and verify) algorithms in zero-knowledge. It offers a high-level API to easily design circuits and fast impleme

ConsenSys Software 510 Jun 24, 2022
gnark is a fast, open-source library for zero-knowledge proof protocols written in Go

gnark gnark is a framework to execute (and verify) algorithms in zero-knowledge. It offers a high-level API to easily design circuits and fast impleme

ConsenSys Software 1.3k Jun 1, 2021
Hexya business application development framework

Hexya Hexya is an open source ERP and a business application development framework written in Go. This repository houses the business application deve

Hexya 352 Jun 20, 2022