https://chinaevent.microsoft.com/events
Micro architecture & design patterns for microservices https://micro.mu/blog/2016/04/18/micro-architecture.html
Introducing Micro – a microservice ecosystem
https://micro.mu/blog/2016/03/17/introduction.html
https://docs.microsoft.com/en-us/azure/architecture/patterns/
类是有行为的数据,为闭包是有数据的行为;
go mod tidy
gin.Default()
- using env: export GIN_MODE=release
- using code: gin.SetMode(gin.ReleaseMode)
gin.SetMode(gin.ReleaseMode)
gin.SetMode(gin.DebugMode)
os.Create
io.MultiWriter
gin.DefaultWriter
go get -u github.com/logrusorgru/aurora
go get -u github.com/mattn/go-colorable
https://segmentfault.com/blog/eddycjy
有一点值得注意,golang的不定参数不需要强制绑定参数的出现。
举个例子,我想在c语言中实现一个求和任意个整数的函数sum:
int sum(int num, …) {
// todo
}
我们只有先指定至少一个非不定参数的形参(num)才能使用…不定参数,在golang中是不需要这样做的:
func sum(nums …int) int {
//todo
}
这也是golang语法简洁的其中一个体现。
了解golang的不定参数(… parameters),这一篇就够了
原文
https://studygolang.com/articles/27387
本站部分文章源于互联网,本着传播知识、有益学习和研究的目的进行的转载,为网友免费提供。如有著作权人或出版方提出异议,本站将立即删除。如果您对文章转载有任何疑问请告之我们,以便我们及时纠正。PS:推荐一个微信公众号: askHarries 或者qq群:474807195,里面会分享一些资深架构师录制的视频录像:有Spring,MyBatis,Netty源码分析,高并发、高性能、分布式、微服务架构的原理,JVM性能优化这些成为架构师必备的知识体系。还能领取免费的学习资源,目前受益良多

转载请注明原文出处:Harries Blog™ » gin开发