In terms of cache stability, basically, every cache-related article and share on the web talks about three key points.
Why talk about cache stability in the first place? You can recall when we introduce caching? Usually it is when the DB is under pressure or even frequently hit and hung that we introduce caching, so we first introduced the caching system to solve the stability problem.
The reason for the existence of cache penetration is the request for non-existent data, from the figure we can see that request 1 for the same data will…
Go is normally used to write backend services. Generally, a request is completed by multiple serial or parallel subtasks. Each subtask may issue another internal request. When the request times out, it’s better to return quickly and release the occupied resources, such as goroutines, file descriptors, etc.
alpine, it's only about 5MB.
RUN apk add --no-cache tzdata
ENV TZ America/New_York
GO111MODULE=on go get -u github.com/tal-tech/go-zero/tools/goctl
greet, create a service called
goctl api new hello