(ctx context.Context, cn *Conn)
| 97 | } |
| 98 | |
| 99 | func (p *StickyConnPool) Put(ctx context.Context, cn *Conn) { |
| 100 | defer func() { |
| 101 | if recover() != nil { |
| 102 | p.freeConn(ctx, cn) |
| 103 | } |
| 104 | }() |
| 105 | p.ch <- cn |
| 106 | } |
| 107 | |
| 108 | func (p *StickyConnPool) freeConn(ctx context.Context, cn *Conn) { |
| 109 | if err := p.badConnError(); err != nil { |