亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? pooleddatasource.java

?? c3p0數據庫連接池實現源碼
?? JAVA
字號:
/* * Distributed as part of c3p0 v.0.9.1-pre6 * * Copyright (C) 2005 Machinery For Change, Inc. * * Author: Steve Waldman <swaldman@mchange.com> * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License version 2.1, as  * published by the Free Software Foundation. * * This software is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this software; see the file LICENSE.  If not, write to the * Free Software Foundation, Inc., 59 Temple Place, Suite 330, * Boston, MA 02111-1307, USA. */package com.mchange.v2.c3p0;import java.sql.SQLException;import javax.sql.DataSource;import java.util.Collection;/** *  <p><b>Most clients need never use or know about this interface -- c3p0 pooled DataSources *  can be treated like any other DataSource.</b></p> * *  <p>The functionality in this interface will be only be of interest if 1) for administrative *  reasons you like to keep close track of the number and status of all Connections your application *  is using; 2) to work around problems encountered while managing a DataSource whose clients are *  poorly coded applications that leak Connections, but which you are not permitted to fix;  *  or 3) to work around problems that may occur if an underlying jdbc driver / DBMS system is *  unreliable. In the third case, most users will be better off not using the present interface *  at all, and using the DataSources' <tt>maxIdleTime</tt>, <tt>idleConnectionTestPeriod</tt>, *  or <tt>testConnectionOnCheckout</tt> parameters to help your DataSources "automatically" heal.  *  But for those who prefer a more direct, manual approach, this interface is for you. It is anticipated *  that the methods of this interface will primarily be of use to administrators managing c3p0 *  PooledDataSources via JMX MBeans.</p> * *  <a name="peruserpools"><h3>Method Names & Per-User Pools</h3></a> * *  <p>To understand this interface, you need to realize that a c3p0 PooledDataSource may represent *  not just one pool of Connections, but many, if users call the method *  <tt>Connection getConnection(String username, String password)</tt> rather than the *  no-argument <tt>getConnection()</tt> method. If users make use of non-default username, password *  combinations, there will be a separate pool for each set of authentification criteria supplied.</p> * *  <p>Many methods in this interface have three variants:</p> *  <ol> *    <li><tt><i>&lt;method-name&gt;</i>DefaultUser()</tt></li> *    <li><tt><i>&lt;method-name&gt;</i>(String username, String password)</tt></li> *    <li><tt><i>&lt;method-name&gt;</i>AllUsers()</tt></li> *  </ol> *  <p>The first variant makes use of the pool maintained for the default user -- *  Connections created by calls to the no argument <tt>getConnection()</tt>, *  the second variant lets you keeps track of pools created by calling  *  <tt>getConnection( <i>username</i>, <i>password</i> )</tt>, and the third variant *  provides aggregate information or performs operation on all pools.</p>  * *  <p>Under most circumstances, non-default authentication credentials will not *  be used, and methods of the first variant are sufficient to manage the DataSource.</p>  * *  <h3>Soft and Hard Resets</h3> * *  <p>A properly configured PooledDataSource whose applications are careful to close all checked-out Connections *  would never need to use these methods. But, sometimes applications are untrustworthy *  and leak Connections, or database administrators suspect that Connections may be corrupt or invalid, *  and would like to force a pool to flush and acquire fresh Connections. This interface provides two  *  ways to do so.</p> * *  <ol> *    <li><b><tt>hardReset()</tt></b> immediately closes all Connections managed by the DataSource, including *    those that are currently checked out, bringing the DataSource back to the state it was in before *    the first client called getConnection(). This method is obviously disruptive, and should be with *    great care. Administrators who need to work around client applications that leak Connections, can *    periodically poll for pool exhaustion (using the methods of this class, or by attempting to retrieve *    a Connection and timing out) and use this method clean-up all Connections and start over. But calling *    this method risks breaking Connections in current use by valid applications.<br/><br/></li> * *    <li><b><tt>softResetDefaultUser()</tt></b>, <b><tt>softReset( <i>username</i>, <i>password</i> )</tt></b> and *    <b><tt>softResetAllUsers()</tt></b> asks the DataSource to flush its current pool of Connections and *    reacquire <i>without</i> invalidating currently checked-out Connections. Currently checked out Connections *    are logically removed from the pool, but their destruction is deferred until a client attempts to close() / check-in *    the Connection. Administrators who suspect that some Connections in the pool may be invalid, but who do not *    wish to rely upon c3p0's automatic testing and detection mechanisms to resolve the problem, may call these *    methods to force a refresh without disrupting current clients. Administrators who suspect that clients may be *    leaking Connections may minimize disruptive hardReset() calls by using softReset() until the number of unclosed *    orphaned connections reaches an unacceptable level. (See <a href="#peruserpools">above</a> to understand *    why there are three variants of this method.)</li>  *  </ol> * *  <h3>Understanding Connection Counts</h3> * *  <p>For each <a href="#peruserpools">per-user pool</a>, four different statistics are available:</p> * *  <ol> *    <li><tt>numConnections</tt> represents the total number of Connections in the pool.<br/><br/></li> *    <li><tt>numIdleConnections</tt> represents the number of Connections in the pool that are currently available for checkout.<br/><br/></li>  *    <li><tt>numBusyConnections</tt> represents the number of Connections in the pool that are currently checked out. The *    invariant <tt>numIdleConnections + numBusyConnections == numConnections</tt> should always hold.<br/><br/></li> *    <li><tt>numUnclosedOrphanedConnections</tt> will only be non-zero following a call to <tt>softReset()</tt>. It represents *    the number of Connections that were checked out when a soft reset occurred and were therefore *    silently excluded from the pool, and which remain unclosed by the client application.</li> *  </ol> */public interface PooledDataSource extends DataSource{    public String getIdentityToken();    public String getDataSourceName();    public void setDataSourceName(String dataSourceName);    /** @deprecated use getNumConnectionsDefaultUser() */    public int getNumConnections() throws SQLException;    /** @deprecated use getNumIdleConnectionsDefaultUser() */    public int getNumIdleConnections() throws SQLException;    /** @deprecated use getNumBusyConnectionsDefaultUser() */    public int getNumBusyConnections() throws SQLException;    /** @deprecated use getNumUnclosedOrphanedConnectionsDefaultUser() */    public int getNumUnclosedOrphanedConnections() throws SQLException;    public int getNumConnectionsDefaultUser() throws SQLException;    public int getNumIdleConnectionsDefaultUser() throws SQLException;    public int getNumBusyConnectionsDefaultUser() throws SQLException;    public int getNumUnclosedOrphanedConnectionsDefaultUser() throws SQLException;    /**     * Discards all Connections managed by the PooledDataSource's default-authentication pool     * and reacquires new Connections to populate.     * Current checked out Connections will still     * be valid, and should still be checked into the     * PooledDataSource (so the PooledDataSource can destroy      * them).     */    public void softResetDefaultUser() throws SQLException;    public int getNumConnections(String username, String password) throws SQLException;    public int getNumIdleConnections(String username, String password) throws SQLException;    public int getNumBusyConnections(String username, String password) throws SQLException;    public int getNumUnclosedOrphanedConnections(String username, String password) throws SQLException;    /**     * Discards all Connections managed by the PooledDataSource with the specified authentication credentials     * and reacquires new Connections to populate.     * Current checked out Connections will still     * be valid, and should still be checked into the     * PooledDataSource (so the PooledDataSource can destroy      * them).     */    public void softReset(String username, String password) throws SQLException;    public int getNumBusyConnectionsAllUsers() throws SQLException;    public int getNumIdleConnectionsAllUsers() throws SQLException;    public int getNumConnectionsAllUsers() throws SQLException;    public int getNumUnclosedOrphanedConnectionsAllUsers() throws SQLException;    /**     * Discards all Connections managed by the PooledDataSource     * and reacquires new Connections to populate.     * Current checked out Connections will still     * be valid, and should still be checked into the     * PooledDataSource (so the PooledDataSource can destroy      * them).     */    public void softResetAllUsers() throws SQLException;    public int getNumUserPools() throws SQLException;    public Collection getAllUsers() throws SQLException;    /**     * Destroys all pooled and checked-out Connections associated with     * this DataSource immediately. The PooledDataSource is     * reset to its initial state prior to first Connection acquisition,     * with no pools yet active, but ready for requests.       */    public void hardReset() throws SQLException;    /**     * <p>C3P0 pooled DataSources use no resources before they are actually used in a VM,     * and they close themselves in their finalize() method. When they are active and     * pooling, they may have open database connections and their pool may spawn several threads     * for its maintenance. You can use this method to clean these resource methods up quickly     * when you will no longer be using this DataSource. The resources will actually be cleaned up only if      * no other DataSources are sharing the same pool.</p>     *     * <p>You can equivalently use the static method destroy() in the DataSources class to clean-up     * these resources.</p>     *     * <p>This is equivalent to calling close( false ).</p>     *     * @see DataSources#destroy     */    public void close() throws SQLException;    /**     * <p>Should be used only with great caution. If <tt>force_destroy</tt> is set to true,     *    this immediately destroys any pool and cleans up all resources     *    this DataSource may be using, <u><i>even if other DataSources are sharing that     *    pool!</i></u> In general, it is difficult to know whether a pool is being shared by     *    multiple DataSources. It may depend upon whether or not a JNDI implementation returns     *    a single instance or multiple copies upon lookup (which is undefined by the JNDI spec).</p>     *     * <p>In general, this method should be used only when you wish to wind down all c3p0 pools     *    in a ClassLoader. For example, when shutting down and restarting a web application     *    that uses c3p0, you may wish to kill all threads making use of classes loaded by a      *    web-app specific ClassLoader, so that the ClassLoader can be cleanly garbage collected.     *    In this case, you may wish to use force destroy. Otherwise, it is much safer to use     *    the simple destroy() method, which will not shut down pools that may still be in use.</p>     *     * <p><b>To close a pool normally, use the no argument close method, or set <tt>force_destroy</tt>     *    to false.</b></p>     *     *   @see #close()     */    public void close(boolean force_destory) throws SQLException;}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
成人黄色在线视频| 日韩视频一区二区三区| 婷婷综合在线观看| 精品久久久久一区二区国产| 成人中文字幕合集| 亚洲第一主播视频| 亚洲成人免费av| 久久精品人人做人人爽97 | 免费成人在线视频观看| 久久九九国产精品| 91精品一区二区三区在线观看| 国内久久精品视频| 蜜桃av噜噜一区| 亚洲一卡二卡三卡四卡五卡| 久久久综合九色合综国产精品| 欧美日韩色一区| 91福利社在线观看| 国产91精品久久久久久久网曝门| 免费xxxx性欧美18vr| 亚洲高清不卡在线观看| 一区二区三区欧美在线观看| 亚洲欧美电影一区二区| 亚洲精品视频在线| 亚洲图片欧美一区| 日韩专区中文字幕一区二区| 丝袜亚洲另类丝袜在线| 午夜精品免费在线| 日本欧美韩国一区三区| 国产综合久久久久久鬼色 | 久久久综合精品| 久久久国产精品午夜一区ai换脸| 精品国产三级电影在线观看| 久久久久久久综合狠狠综合| 国产精品久久久久毛片软件| 亚洲欧美日韩系列| 日本怡春院一区二区| 蜜臀av一区二区三区| 成人免费毛片aaaaa**| 99国产精品一区| 91精品国产综合久久久久久漫画| 精品久久久久久久久久久久久久久 | 91看片淫黄大片一级| 6080午夜不卡| 亚洲精品自拍动漫在线| 日韩一区精品视频| 波多野结衣的一区二区三区| 欧美一区二区三区视频免费播放 | 99久久精品久久久久久清纯| 在线一区二区三区四区五区| 久久精品亚洲精品国产欧美kt∨ | 欧美一级淫片007| 自拍偷拍欧美激情| 国产成人亚洲综合a∨婷婷| 欧美日韩精品三区| 亚洲人亚洲人成电影网站色| 国产一区在线不卡| 欧美丰满少妇xxxbbb| 一区二区三区在线视频免费观看| 国产精品白丝jk黑袜喷水| 欧美一区三区二区| 日韩精品乱码免费| 欧美午夜寂寞影院| 亚洲一区二区三区中文字幕| 91网站视频在线观看| 国产蜜臀97一区二区三区| 毛片一区二区三区| 日韩女优制服丝袜电影| 日韩中文字幕不卡| 91精品麻豆日日躁夜夜躁| 亚洲综合免费观看高清完整版| 一本久道久久综合中文字幕| 综合久久久久久久| 欧美色网站导航| 日韩国产精品大片| 精品国产一区二区三区四区四| 日韩电影免费一区| 欧美丰满少妇xxxxx高潮对白| 五月天网站亚洲| 久久久99精品免费观看不卡| 国产成a人亚洲精| 国产欧美日韩三区| 色系网站成人免费| 麻豆91精品91久久久的内涵| 欧美夫妻性生活| 国产sm精品调教视频网站| 中文成人综合网| 欧美亚洲综合一区| 国产一区二区三区在线观看免费视频| 91精品国产综合久久福利 | 有码一区二区三区| 日韩免费视频一区| 懂色av一区二区三区免费观看| 一区二区三区欧美日韩| 精品裸体舞一区二区三区| 99久久精品99国产精品 | 国产福利电影一区二区三区| 亚洲一区二区三区国产| 国产日韩欧美精品综合| 欧美日韩一本到| 国产精品美女一区二区在线观看| 韩国欧美一区二区| 日韩视频免费观看高清完整版在线观看| 色天天综合色天天久久| 毛片基地黄久久久久久天堂| 中文字幕欧美激情| 国产亚洲一区字幕| 久久婷婷色综合| 精品国产乱码久久久久久蜜臀| 7777精品伊人久久久大香线蕉的 | 91尤物视频在线观看| 国产毛片精品视频| 亚洲国产综合在线| 亚洲品质自拍视频| 亚洲欧美一区二区三区极速播放 | 91 com成人网| 精品粉嫩aⅴ一区二区三区四区| 欧美一级欧美三级| 国产午夜亚洲精品理论片色戒 | 国产精品国产三级国产普通话三级 | 亚洲欧洲成人自拍| 日韩国产在线一| 国产精品免费久久久久| 国产精品婷婷午夜在线观看| 夜夜嗨av一区二区三区| 欧美大片在线观看一区二区| 久久日韩粉嫩一区二区三区| 欧美一区二区视频在线观看| 欧美成人在线直播| 国产欧美一区视频| 亚洲精品国产品国语在线app| 国产精品乱码久久久久久| 亚洲视频一二三区| 亚洲亚洲人成综合网络| 久久国产精品99久久人人澡| youjizz国产精品| 国产欧美一区二区精品婷婷| 国产高清视频一区| 久久综合99re88久久爱| 成人aa视频在线观看| 国产精品女人毛片| 91久久精品一区二区| 日韩av电影天堂| 国产精品成人在线观看| 欧美日韩三级一区| 精品制服美女丁香| 亚洲另类色综合网站| 91麻豆精品久久久久蜜臀| 成人黄色在线看| 久久超碰97人人做人人爱| 中文字幕日韩av资源站| 国产不卡高清在线观看视频| 国产欧美日韩久久| 97久久超碰国产精品| 亚洲乱码一区二区三区在线观看| 成人免费观看av| 亚洲精品国产精品乱码不99| 欧美日韩久久久久久| 日韩国产高清影视| 久久精品免费在线观看| 91麻豆精品一区二区三区| 亚洲一区二三区| 欧美xfplay| 91免费国产在线观看| 日韩高清不卡在线| 国产欧美一区二区三区鸳鸯浴| 日本韩国欧美一区二区三区| 蜜桃精品视频在线| 综合中文字幕亚洲| 欧美tickling挠脚心丨vk| 99热精品国产| 国产一区二区按摩在线观看| 亚洲一区在线免费观看| 国产日韩精品一区| 91精品国产高清一区二区三区蜜臀| 国产精品乡下勾搭老头1| 一区2区3区在线看| 国产精品伦理一区二区| 日韩一区二区视频| 欧美日韩视频在线观看一区二区三区| 久久精品久久99精品久久| 午夜精品一区二区三区免费视频| 国产精品久久久久久久久免费丝袜| 欧美精品日韩综合在线| 91丨porny丨在线| 成人自拍视频在线观看| 国产综合色在线| 青青草国产成人99久久| 午夜在线电影亚洲一区| 午夜精品免费在线| 视频精品一区二区| 一区二区三区在线免费播放| 国产精品久久久久久亚洲毛片| 国产精品久久久久久久岛一牛影视| 国产欧美精品在线观看| 亚洲国产精品ⅴa在线观看| 国产精品卡一卡二卡三| 亚洲欧洲日产国码二区| 午夜日韩在线电影| 男女性色大片免费观看一区二区| 国产精品综合av一区二区国产馆|