Configuring to Debug and Workaround Broken Client Applications
背景:C3P0数据库连接池占满
Configuring to Debug and Workaround Broken Client Applications 
Sometimes client applications are sloppy about close()ing all Connections they check out. Eventually, the pool grows to
maxPoolSize, and then runs out of Connections, because of these bad clients.
The right way to address this problem is to fix the client application. c3p0 can help you debug, by letting you know where Connections are checked out that occasionally don't get checked in. In rare and unfortunate situations, development of the
client application is closed, and even though it is buggy, you cannot fix it. c3p0 can help you work around the broken application, preventing it from exhausting the pool.
The following parameters can help you debug or workaround broken client applications.
unreturnedConnectionTimeout defines a limit (in seconds) to how long a Connection may remain checked out. If set to a nozero value, unreturned, checked-out Connections that exceed this limit will be summarily destroyed, and then replaced in the
pool. Obviously, you must take care to set this parameter to a value large enough that all intended operations on checked out Connections have time to complete. You can use this parameter to merely workaround unreliable client apps that fail to close() Connections.
Much better than working-around is fixing. If, in addition to setting
unreturnedConnectionTimeout, you set debugUnreturnedConnectionStackTraces to
true, then a stack trace will be captured each time a Connection is checked-out. Whenever an unreturned Connection times out, that stack trace will be printed, revealing where a Connection was checked out that was not checked in promptly.
debugUnreturnedConnectionStackTraces is intended to be used only for debugging, as capturing a stack trace can slow down Connection check-out.
Configuring to Debug and Workaround Broken Client Applications的更多相关文章
- Asynchronous vs synchronous client applications(MQTT)
来自我的CSDN博客 想查看英文原文的请点击原文网址.在上两篇翻译中,Homejim我给大家分别翻译了同步客户端应用程序和异步客户端应用程序.本人对这两个的区别也有困惑,因此将paho下的这个比较 ...
- Learning WCF Chapter1 Generating a Service and Client Proxy
In the previous lab,you created a service and client from scratch without leveraging the tools avail ...
- [转]Publishing and Running ASP.NET Core Applications with IIS
本文转自:https://weblog.west-wind.com/posts/2016/Jun/06/Publishing-and-Running-ASPNET-Core-Applications- ...
- 通过Instant Client包来使用SQL*PLUS
1.首先下载两个程序包: Instant Client Package - Basic(或Instant Client Package - Basic Lite)包 Instant Client Pa ...
- udhcpd源码分析4--获取client报文及发包动作
1:重要的结构体 获取的报文是UDP的payload部分,结构体struct dhcpMessage描述了dhcp报文的结构. /* packet.h */ struct dhcpMessage { ...
- 微软职位内部推荐-Principal DEV Manager for Bing Client
微软近期Open的职位: Title: Principal DEV Manager for Bing ClientGroup: Search Technology Center Asia, BingW ...
- .net framework client profile
.NET Framework Client Profile The .NET Client Profile is a subset of the .NET Framework, which was p ...
- MQTT Client library for C (MQTT客户端C语言库-paho)
原文:http://www.eclipse.org/paho/files/mqttdoc/MQTTClient/html/index.html 来自我的CSDN博客 最近在使用Paho的MQTT客 ...
- [转]Consuming a OData Service in a Client Application (WCF Data Services)
本文转自:https://msdn.microsoft.com/zh-tw/library/dd728282(v=vs.103).aspx WCF Data Services 5.0 其他版本 ...
随机推荐
- idae for mac部分背景色修改收集
文章目录 所有字体默认颜色 终端背景色 行数line number背景色 line number颜色 编码区背景色 光标所在行背景色 未被使用的变量.方法或者类 控制台相关 选中文字的背景色 选中和未 ...
- SSH整合时执行hibernate查询报错:java.lang.ClassCastException: com.ch.hibernate.Depart
今天在整合ssh三个框架时,有一个功能,是查询所有员工信息,且员工表和部门表是多对一的映射关系,代码能正常运行到查询得到一个List集合,但在页面展示的时候,就报异常了, java.lang.Clas ...
- day 68 Django基础四之模板系统
Django基础四之模板系统 本节目录 一 语法 二 变量 三 过滤器 四 标签Tags 五 模板继承 六 组件 七 自定义标签和过滤器 八 静态文件相关 一 语法 模板渲染的官方文档 关 ...
- 《DSP using MATLAB》Problem 8.38
代码: function [wpLP, wsLP, alpha] = bp2lpfre(wpbp, wsbp) % Band-edge frequency conversion from bandpa ...
- 求教各路大神,Fillder的证书一直无法在手机上打开,请教怎么解决
我跟足大神们的设置,软件是Fiddler4,手机是ios12.3.1. FD上该打勾的打勾了,该装证书的也装了,有帖子说重装证书和软件我也都试过,电脑也下了NET Framework 4.7_4.7. ...
- 使用APOC技术从MYSQL数据库导数据到Neo4j图数据库(JDBC)
Neo4j 数据导入 一.安装与部署Neo4j 直接在官网下载安装包安装,解压即可. 2.mysql ...
- MapReduce应用程序执行过程
- T3118 01完美矩阵【计数,前缀和,差分,好题】
Online Judge:未知 Label:好题,计数,前缀和 题目描述 一个01矩形被称为是完美01矩形,如果满足下面3个条件: (1)它的四条边上都是1 (2)内部(除了4条边)的0和1的个数之差 ...
- 【案例】DIV随鼠标移动而移动
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...
- Algo: Dynamic programming
Copyright © 1900-2016, NORYES, All Rights Reserved. http://www.cnblogs.com/noryes/ 欢迎转载,请保留此版权声明. -- ...