package connection_pool import ( "dbview/service/internal/common/manager/connection" "dbview/service/internal/modules/connection_pool/handler" "dbview/service/internal/modules/connection_pool/service" "github.com/gin-gonic/gin" ) // RegisterRoutes 注册连接池管理相关路由 func RegisterRoutes(engine *gin.Engine, pool *connection.ConnectionPool) { service.Init(pool) group := engine.Group("/api/v1/connection_pool") { group.POST("/register", handler.RegisterConnection) group.POST("/stats", handler.GetConnectionStats) group.POST("/close", handler.CloseConnection) group.POST("/close_all", handler.CloseAllConnections) group.POST("/ping", handler.PingConnection) } }