Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
nange committed Nov 8, 2017
1 parent 3444e54 commit 5ad858a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ if err != nil {
// 使用完连接之后,调用Close发放,当前连接会重新放回到pool中
conn.Close()

// 如果需要直接关闭底层连接(比如底层连接已经失效),则:
conn.(*PoolConn).MarkUnusable()
conn.Close()

// 释放当前连接池中所有连接
pool.Close()

Expand Down

0 comments on commit 5ad858a

Please sign in to comment.