zhoushuguang / beyond Goto Github PK
View Code? Open in Web Editor NEWBased on the go-zero framework of large-scale microservices practical project, see all say yes!
Based on the go-zero framework of large-scale microservices practical project, see all say yes!
message ArticlesRequest {
int64 userId = 1;
int64 cursor = 2;
int64 pageSize = 3;
int32 sortType = 4;
int64 articleId = 5;
}
articleId ,用途是啥?
大佬 想问下这个项目之后的大致发展以及有没有什么需要contribute的地方。
要是有个roadmap可以没事写写额外需求 😄
创建索引时用的是KEY
ix_update_time (
update_time)
实际上没有update_time这个字段,
请将上方update_mtime字段改成update_time
或是将索引改为KEY
ix_update_time (
update_mtime)
{"@timestamp":"2024-04-05T10:54:53.334+08:00","caller":"internal/log.go:77","content":"(/v1/article/publish - [::1]:48618) runtime error: invalid memory address or nil pointer dereference\ngoroutine 88 [running]:\nruntime/debug.Stack()\n\t/usr/lib/go/src/runtime/debug/stack.go:24 +0x5e\ngithub.com/zeromicro/go-zero/rest/handler.RecoverHandler.func1.1()\n\t/home/zoedoet/go/pkg/mod/github.com/zeromicro/[email protected]/rest/handler/recoverhandler.go:16 +0x58\npanic({0x1a2a1e0?, 0x2e4ee30?})\n\t/usr/lib/go/src/runtime/panic.go:770 +0x132\nbeyond/application/article/api/internal/logic.(*PublishLogic).Publish(0xc00017ce40, 0xc0004a4bc0)\n\t/home/zoedoet/workspace/go/beyond/application/article/api/internal/logic/publishlogic.go:45 +0x10a\nbeyond/application/article/api/internal/handler.RegisterHandlers.PublishHandler.func2({0x1fa4278, 0xc00010f200}, 0xc0001cab40)\n\t/home/zoedoet/workspace/go/beyond/application/article/api/internal/handler/publishhandler.go:21 +0x8f\nnet/http.HandlerFunc.ServeHTTP(0x0?, {0x1fa4278?, 0xc00010f200?}, 0x0?)\n\t/usr/lib/go/src/net/http/server.go:2166 +0x29\ngithub.com/zeromicro/go-zero/rest/handler.GunzipHandler.func1({0x1fa4278, 0xc00010f200}, 0xc0001cab40)\n\t/home/zoedoet/go/pkg/mod/github.com/zeromicro/[email protected]/rest/handler/gunziphandler.go:26 +0xb1\nnet/http.HandlerFunc.ServeHTTP(0x7a2afa4971bfd5?, {0x1fa4278?, 0xc00010f200?}, 0xc17bf7df53efd215?)\n\t/usr/lib/go/src/net/http/server.go:2166 +0x29\ngithub.com/zeromicro/go-zero/rest.(*engine).buildChainWithNativeMiddlewares.MaxBytesHandler.func8.1({0x1fa4278?, 0xc00010f200?}, 0x2e8b420?)\n\t/home/zoedoet/go/pkg/mod/github.com/zeromicro/[email protected]/rest/handler/maxbyteshandler.go:24 +0xf8\nnet/http.HandlerFunc.ServeHTTP(0x0?, {0x1fa4278?, 0xc00010f200?}, 0x0?)\n\t/usr/lib/go/src/net/http/server.go:2166 +0x29\ngithub.com/zeromicro/go-zero/rest.(*engine).buildChainWithNativeMiddlewares.MetricHandler.func6.1({0x1fa4278, 0xc00010f200}, 0xc0001cab40)\n\t/home/zoedoet/go/pkg/mod/github.com/zeromicro/[email protected]/rest/handler/metrichandler.go:21 +0xae\nnet/http.HandlerFunc.ServeHTTP(0x0?, {0x1fa4278?, 0xc00010f200?}, 0x0?)\n\t/usr/lib/go/src/net/http/server.go:2166 +0x29\ngithub.com/zeromicro/go-zero/rest/handler.RecoverHandler.func1({0x1fa4278?, 0xc00010f200?}, 0x0?)\n\t/home/zoedoet/go/pkg/mod/github.com/zeromicro/[email protected]/rest/handler/recoverhandler.go:21 +0x78\nnet/http.HandlerFunc.ServeHTTP(0x0?, {0x1fa4278?, 0xc00010f200?}, 0x0?)\n\t/usr/lib/go/src/net/http/server.go:2166 +0x29\ngithub.com/zeromicro/go-zero/rest/handler.(*timeoutHandler).ServeHTTP.func1()\n\t/home/zoedoet/go/pkg/mod/github.com/zeromicro/[email protected]/rest/handler/timeouthandler.go:82 +0x71\ncreated by github.com/zeromicro/go-zero/rest/handler.(*timeoutHandler).ServeHTTP in goroutine 15\n\t/home/zoedoet/go/pkg/mod/github.com/zeromicro/[email protected]/rest/handler/timeouthandler.go:76 +0x319\n","level":"error","span":"c4442d8f3e35d519","trace":"5a53e69257ce72e80e9b8f1e48214afe"}
{"@timestamp":"2024-04-05T10:54:53.334+08:00","caller":"handler/loghandler.go:157","content":"[HTTP] 500 - POST /v1/article/publish - [::1]:48618 - PostmanRuntime/7.37.0\nPOST /v1/article/publish HTTP/1.1\r\nHost: localhost:8889\r\nAccept: /\r\nAccept-Encoding: gzip, deflate, br\r\nAuthorization: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE3MTI4ODY0NjUsImlhdCI6MTcxMjI4MTY2NSwidXNlcklkIjoyfQ.ol3awBLorwMqU7UQSz0kIO3pD3rFGgsWFCF7vjuxlrw\r\nConnection: keep-alive\r\nContent-Length: 718\r\nContent-Type: application/json\r\nPostman-Token: 045a2ba7-8d7b-4c65-a11f-fbb44d34fa16\r\nUser-Agent: PostmanRuntime/7.37.0\r\n\r\n{\n "title":"article_1",\n "content":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx","duration":"0.2ms","level":"error","span":"c4442d8f3e35d519","trace":"5a53e69257ce72e80e9b8f1e48214afe"}
beyond/application/article/rpc/internal/logic/articleslogic.go
里面的cmp包以及 slices 是哪来的?
现在的接口逻辑中参数校验需要手动校验 比如
if len(req.Password) == 0 { return nil, code.RegisterPasswdEmpty }
可以引入 Validator 通过tag来作这些事情吗? up 可以来讨论下吗? 合适的话我可以做这个~~
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.