go-zero icon indicating copy to clipboard operation
go-zero copied to clipboard

A cloud-native Go microservices framework with cli tool for productivity.

Results 430 go-zero issues
Sort by recently updated
recently updated
newest added

I notice that all the p.cond.Wait() and p.cond.Signal() are protected by the mutex lock r.cond.L.Lock() in the file https://github.com/zeromicro/go-zero/blob/master/core/syncx/pool.go#LL82C16-L82C16. So I doubt whether this situation can cause a deadlock. Maybe...

stale

go-zero自动生成的crud如下: ```go subscriptionsModel interface { Insert(ctx context.Context, data *Subscriptions) (sql.Result, error) FindOne(ctx context.Context, id int64) (*Subscriptions, error) Update(ctx context.Context, data *Subscriptions) error Delete(ctx context.Context, id int64) error } usersModel interface...

goctl工具很方便,但是模版里面很多地方不统一 1:model里面 ![image](https://github.com/zeromicro/go-zero/assets/9391575/7d745c21-ae54-4054-8b6e-674cc64bb96c) 在这块可以在生成名字后加上model 2:rpc里面 ![image](https://github.com/zeromicro/go-zero/assets/9391575/3f30a54a-4b3e-4969-9906-87f3ab056a81) 也是如此,加上了server 3:api里面 ![image](https://github.com/zeromicro/go-zero/assets/9391575/d7b10d7e-8bbe-40c2-9918-53cb95e7e44c) 但是在api中handler和logic中就直接把 handler和logic写死了, 给人感觉各种风格不统一 其次是: 文件实在logic和handler下面了,文件名后面还加一个logic和handler,就感觉是非要在强调一次的感觉。 希望这些都可以在模版中配置吧。灵活度也高。自己配置成统一风格

answered

删除项目日志文件 `cat /dev/null > access.log` 后,查看access.log文件大小依然是原来大小,但`du -hd1`查看当前目录确实已经变小了 然而先del access.log后,再restart服务,access.log就正常了 希望能支持linux下可手工清理log

feature
area/logs

please see my test code: ``` func TestMrTimeout(t *testing.T) { start := time.Now() ctx, cancel := context.WithTimeout(context.Background(), time.Second*1) defer cancel() mr.WithContext(ctx) var apiFuncs []func() error var result []string apiFuncs =...

stale

现在有一个示例: 我有一个api服务,调用了10个grpc服务。这些服务使用etcd进行服务发现。 现在有一个grpc服务因为bug全部下线了。etcd 中没有这个服务的任何ip。 这个时候,我的api服务正在进行bug的紧急修复,需要立马上线。 但是这个时候,这一个grpc服务因为bug未修复启动不了(暂不考虑回滚情况),导致我的api服务也无法发布。 我应该如何面对这个问题才能让api能正常的发布上线,并在grpc服务恢复的时候,api服务通过etcd重新能发现这个grpc服务? --- Now here is an example: I have an api service that calls 10 grpc services. These services use etcd for service discovery....

stale

Windows 系统下logx设置了KeepDays无法正常删除过期日志, 问题代码 core/logx/writer.go:133 accessFile := path.Join(c.Path, accessFilename) 拿到的 目录地址为 ”logs/access.log“ 后续删除时的判断: core/logx/rotatelogger.go:126 for _, file := range files { if file < boundaryFile { outdates = append(outdates, file) }...

stale

There is a denial of service vulnerability in go 1.18 disclosed under [CVE-2023-24534](https://nvd.nist.gov/vuln/detail/CVE-2023-24534). This vulnerability has been patched in version 1.19 and 1.20 but not in 1.18, discussed [here](https://github.com/golang/go/issues/58975).

stale

**Description of the error** I encountered the error "import cycle not allowed" when importing nested files using .api **Recreate** Steps to reproduce the behavior, if applicable: 1. multiple files exist...

stale

**Is your feature request related to a problem? Please describe.** I hope to achieve a common format response, like ```go type CommonResp struct { Code int `json:"code"` Msg string `json:"msg"`...

stale