refactor: simplify architecture and harden lifecycle

Remove obsolete implementations, centralize background task ownership and terminal-state recovery, consolidate frontend routing and log streaming, and enforce project-wide verification in CI.
This commit is contained in:
Awuqing
2026-08-26 11:32:00 +08:00
parent 95b27af600
commit c06bbec383
189 changed files with 8983 additions and 4264 deletions
+1 -3
View File
@@ -46,9 +46,7 @@ func (h *HealthHandler) Ready(c *gin.Context) {
checks["database"] = "error: " + err.Error()
overallOK = false
} else {
ctx, cancel := c.Request.Context(), func() {}
_ = cancel
if err := sqlDB.PingContext(ctx); err != nil {
if err := sqlDB.PingContext(c.Request.Context()); err != nil {
checks["database"] = "ping failed: " + err.Error()
overallOK = false
} else {
+1
View File
@@ -399,6 +399,7 @@ func NewRouter(deps RouterDependencies) *gin.Engine {
func requestLogger(logger *zap.Logger) gin.HandlerFunc {
return func(c *gin.Context) {
response.SetLogger(c, logger)
c.Next()
logger.Info("http request",
zap.String("method", c.Request.Method),