* Pool for efficient reuse of connections. Usage: pool := client.NewPool(log.Debugf, 100, 400, 5, `127.0.0.1:3306`, `username`, `userpwd`, `dbname`) ... conn, _ := pool.GetConn(ctx) defer pool.PutConn(conn) conn.Execute/conn.Begin/etc... */
| 45 | } |
| 46 | |
| 47 | ConnectionStats struct { |
| 48 | // Uses internally |
| 49 | TotalCount int |
| 50 | |
| 51 | // Only for stats |
| 52 | IdleCount int |
| 53 | CreatedCount int64 |
| 54 | } |
| 55 | |
| 56 | Connection struct { |
| 57 | conn *Conn |
nothing calls this directly
no outgoing calls
no test coverage detected