quartz 2.2.1 jdbc 连接池参数配置
/** The JDBC database driver. */指定连接驱动
public static final String DB_DRIVER = "driver"; /** The JDBC database URL. */ 连接字符串
public static final String DB_URL = "URL"; /** The database user name. */ 用户名
public static final String DB_USER = "user"; /** The database user password. */ 密码
public static final String DB_PASSWORD = "password"; /** The maximum number of database connections to have in the pool. Default is 10. */ 连接池最大连接数
public static final String DB_MAX_CONNECTIONS = "maxConnections"; /**
* The maximum number of prepared statements that will be cached per connection in the pool.
* Depending upon your JDBC Driver this may significantly help performance, or may slightly
* hinder performance.
* Default is 120, as Quartz uses over 100 unique statements. 0 disables the feature.
*/ 每个链接最多缓存多少个预编译语句
public static final String DB_MAX_CACHED_STATEMENTS_PER_CONNECTION = "maxCachedStatementsPerConnection"; /**
* The database sql query to execute every time a connection is returned
* to the pool to ensure that it is still valid.
*/ 验证连接是否可用的查询语句
public static final String DB_VALIDATION_QUERY = "validationQuery"; /**
* The number of seconds between tests of idle connections - only enabled
* if the validation query property is set. Default is 50 seconds.
*/ 多久验证空闲连接
public static final String DB_IDLE_VALIDATION_SECONDS = "idleConnectionValidationSeconds"; /**
* Whether the database sql query to validate connections should be executed every time
* a connection is retrieved from the pool to ensure that it is still valid. If false,
* then validation will occur on check-in. Default is false.
*/ 是否每次从池中取连接时,验证连接可用性
public static final String DB_VALIDATE_ON_CHECKOUT = "validateOnCheckout"; /** Discard connections after they have been idle this many seconds. 0 disables the feature. Default is 0.*/ 空闲连接超过多少秒丢弃
private static final String DB_DISCARD_IDLE_CONNECTIONS_SECONDS = "discardIdleConnectionsSeconds"; /** Default maximum number of database connections in the pool. */ 最大连接数
public static final int DEFAULT_DB_MAX_CONNECTIONS = 10; /** Default maximum number of database connections in the pool. */ 默认每个链接缓存120个预编译语句
public static final int DEFAULT_DB_MAX_CACHED_STATEMENTS_PER_CONNECTION = 120;
quartz连接池配置对C3PO连接池配置进行了一些封装, 留作记录。
mysql 断开连接可以通过设置 validateOnCheckout=true + validationQuery
或者设置discardIdleConnectionsSeconds 少于8小时解决。
quartz 2.2.1 jdbc 连接池参数配置的更多相关文章
- C3P0连接池参数配置
<!--acquireIncrement:链接用完了自动增量3个. --> <property name="acquireIncrement">3</ ...
- HttpClient 4.3连接池参数配置及源码解读
目前所在公司使用HttpClient 4.3.3版本发送Rest请求,调用接口.最近出现了调用查询接口服务慢的生产问题,在排查整个调用链可能存在的问题时(从客户端发起Http请求->ESB-&g ...
- HttpClient4.3 连接池参数配置及源码解读
目前所在公司使用HttpClient 4.3.3版本发送Rest请求,调用接口.最近出现了调用查询接口服务慢的生产问题,在排查整个调用链可能存在的问题时(从客户端发起Http请求->ESB-&g ...
- KettleDB连接jdbc连接池参数介绍
http://sheng8407-sina-com.iteye.com/blog/1163245 http://blog.csdn.net/dingxingmei/article/details/41 ...
- 帆软报表FineReport中数据连接的JDBC连接池属性问题
连接池原理 在帆软报表FineReport中,连接池主要由三部分组成:连接池的建立.连接池中连接使用的治理.连接池的关闭.下面就着重讨论这三部分及连接池的配置问题. 1. 连接池原理 连接池技术的核心 ...
- JDBC连接池。。。转载
1. 引言 近年来,随着Internet/Intranet建网技术的飞速发展和在世界范围内的迅速普及,计算机 应用程序已从传统的桌面应用转到Web应用.基于B/S(Browser/Server)架 ...
- 四大流行的jdbc连接池之C3P0篇
C3P0是一个开放源代码的JDBC连接池,它在lib目录中与Hibernate一起发布,包括了实现jdbc3和jdbc2扩展规范说明的Connection 和Statement 池的DataSourc ...
- JDBC连接池-自定义连接池
JDBC连接池 java JDBC连接中用到Connection 在每次对数据进行增删查改 都要 开启 .关闭 ,在实例开发项目中 ,浪费了很大的资源 ,以下是之前连接JDBC的案例 pack ...
- 【JDBC&Dbutils】JDBC&JDBC连接池&DBUtils使用方法(重要)
-----------------------JDBC---------- 0. db.properties文件 driver=com.mysql.jdbc.Driver url=jdbc: ...
随机推荐
- Super关键字
一.super关键字
- gradle 学习
gradle是个构建工具,目的是为了更方便的管理项目. 学习gradle看下面的资料: 中文资料,总共六篇,看完之后基础差不多了: 简介 第一个Java项目 依赖管理 创建二进制发布版本 创建多项目构 ...
- <转>Python学习推荐
书籍推荐 基本了解: <<A Byte of Python>> (Python简明教程http://sebug.net/paper/python/) 网上有资源,两小时了解基本 ...
- NIS Edit&Nsis打包程序发布(安装和卸载)
转自:http://blog.csdn.net/signjing/article/details/7855855 注意:首选得明确自己需要打包的程序,以及程序需要的dll文件,资源文件等. 1.下载N ...
- (转载)OC学习篇之---类的三大特性:封装,继承,多态
之前的一片文章介绍了OC中类的初始化方法和点语法的使用,今天来继续学习OC中的类的三大特性,我们在学习Java的时候都知道,类有三大特性:继承,封装,多态,这个也是介绍类的时候,必须提到的话题,那么今 ...
- Tkinter教程之Event篇(2)
本文转载自:http://blog.csdn.net/jcodeer/article/details/1823548 '''Tkinter教程之Event篇(2)''''''5.测试离开(Leave) ...
- https://github.com/mlzboy/spider-impl.git
Installation - pygit2 0.24.0 documentation Python 2.7, 3.2+ or PyPy 2.6+ (including the development ...
- 现代程序设计 homework-09
现代程序设计 homework-09 这次作业是要求将homework-02做成一个可演示的应用,目的是为了让用户看到程序的计算步骤以及中间结果. 借此机会也学了一下JavaScript,感觉总结的地 ...
- uniPanel特效
function beforeInit(sender){ sender.layout='accordion'; Ext.apply (sender, {title:'供应链',style:'text- ...
- [C语言 - 7] 结构体struct
A. 基本知识 与数组的对比 数组: 构造类型 只能有多个相同类型的数据构成 结构体: 结构体类型 可以由多个不同类型的数据构成 1. 定义类型 struct Student { int ...