BoneCP correct usage

后端 未结 2 870
走了就别回头了
走了就别回头了 2021-01-02 07:09

I\'ve just started using BoneCP and pulled the sample JDBC code from the authors site.

I have a function called getConnection() that returns a connection here is a s

2条回答
  •  忘掉有多难
    2021-01-02 07:54

    1. Always call connection.close() to return the connection to the pool (it won't be physically closed) when you're done with it.

    2. Call connectionPool.shutDown() when you're completely done with the pool and not planning of reconnecting again.

提交回复
热议问题