ZhangZhihui's Blog  
上一页 1 ··· 77 78 79 80 81 82 83 84 85 ··· 102 下一页

2023年11月16日

摘要: grpc.go is for defining the handlers, and server.go mostly runs the server and register endpoints inside the grpc.go file. While there are no written 阅读全文
posted @ 2023-11-16 08:25 ZhangZhihuiAAA 阅读(34) 评论(0) 推荐(0)

2023年11月15日

摘要: Hexagonal architecture (https://alistair.cockburn.us/hexagonal-architecture/), proposed by Alistair Cockburn in 2005, is an architectural pattern that 阅读全文
posted @ 2023-11-15 21:09 ZhangZhihuiAAA 阅读(25) 评论(0) 推荐(0)

2023年11月14日

摘要: zzh@ZZHPC:~$ sudo apt install -y protobuf-compiler zzh@ZZHPC:/zdata/Github/zimplebank$ protoc --versionlibprotoc 3.12.4 This version is too old. zzh@Z 阅读全文
posted @ 2023-11-14 19:22 ZhangZhihuiAAA 阅读(99) 评论(0) 推荐(0)
 
摘要: Required fields in a message can be thought of as frequently used fields since you cannot skip them as you can for optional fields. It is a best pract 阅读全文
posted @ 2023-11-14 08:58 ZhangZhihuiAAA 阅读(64) 评论(0) 推荐(0)

2023年11月13日

摘要: To have data consistency in a distributed system, you have two options: a two-phase commit (2PC) and saga. 2PC coordinates all the processes that form 阅读全文
posted @ 2023-11-13 18:47 ZhangZhihuiAAA 阅读(13) 评论(0) 推荐(0)

2023年10月23日

摘要: package main import ( "fmt" ) type Person struct { Name string Age int Email string } func main() { p := Person{ Name: "Drake", Age: 35, Email: "drake 阅读全文
posted @ 2023-10-23 20:38 ZhangZhihuiAAA 阅读(13) 评论(0) 推荐(0)

2023年10月18日

摘要: Problem: You want to run performance tests for a specific duration or a specific number of iterations. Solution: You can increase the minimum duration 阅读全文
posted @ 2023-10-18 20:12 ZhangZhihuiAAA 阅读(19) 评论(0) 推荐(0)
 
摘要: Problem: You want to customize the performance tests to avoid benchmarking test fixtures. Solution: You can start, stop, and reset the benchmark timer 阅读全文
posted @ 2023-10-18 20:07 ZhangZhihuiAAA 阅读(18) 评论(0) 推荐(0)
 
摘要: Problem: You want to do unit testing on a web application or a web service. Solution: Use the httptest.NewRecorder function to create an httptest.Resp 阅读全文
posted @ 2023-10-18 19:02 ZhangZhihuiAAA 阅读(13) 评论(0) 推荐(0)
 
摘要: Problem: You want to generate random test data for running your test functions. Solution: Use fuzzing , which is an automated testing technique to gen 阅读全文
posted @ 2023-10-18 18:50 ZhangZhihuiAAA 阅读(19) 评论(0) 推荐(0)
上一页 1 ··· 77 78 79 80 81 82 83 84 85 ··· 102 下一页