createConnection is a factory method that will be called by the pool when a new connection is needed.
()
| 37 | // createConnection is a factory method that will be called by |
| 38 | // the pool when a new connection is needed. |
| 39 | func createConnection() (io.Closer, error) { |
| 40 | id := atomic.AddInt32(&idCounter, 1) |
| 41 | log.Println("Create: New Connection", id) |
| 42 | |
| 43 | return &dbConnection{id}, nil |
| 44 | } |
| 45 | |
| 46 | // main is the entry point for all Go programs. |
| 47 | func main() { |
nothing calls this directly
no outgoing calls
no test coverage detected