能源项目xml文件 -- app-datasource.xml
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
classpath:/org/springframework/beans/factory/xml/spring-beans-4.1.xsd
http://www.springframework.org/schema/context
classpath:/org/springframework/context/config/spring-context-4.1.xsd
http://www.springframework.org/schema/tx
classpath:org/springframework/transaction/config/spring-tx-4.1.xsd"
default-lazy-init="false"> <!-- <context:property-placeholder location="classpath:spring/datasource.properties" /> --> <bean id="dataSource1" class="org.apache.tomcat.jdbc.pool.DataSource" destroy-method="close">
<property name="poolProperties">
<bean class="org.apache.tomcat.jdbc.pool.PoolProperties">
<property name="driverClassName" value="com.mysql.jdbc.Driver" />
<property name="url" value="${jdbc.url}" />
<property name="username" value="${jdbc.user}" />
<property name="password" value="${jdbc.password}" />
<!-- Register the pool with JMX. In order for the connection pool object to create the MBean. -->
<property name="jmxEnabled" value="true" />
<!-- The indication of whether objects will be validated by the idle object evictor. -->
<property name="testWhileIdle" value="true" />
<!-- The indication of whether objects will be validated before being borrowed from the pool. -->
<property name="testOnBorrow" value="false" />
<property name="testOnReturn" value="false" />
<property name="initialSize" value="${jdbc.initialPoolSize}" />
<property name="maxActive" value="${jdbc.maxActive}" />
<property name="maxWait" value="${jdbc.maxWait}" />
<property name="minIdle" value="${jdbc.minIdle}" />
<property name="maxIdle" value="${jdbc.maxIdle}" />
<property name="maxAge" value="60000" />
<!-- The number of milliseconds to sleep between runs of the idle connection validation/cleaner thread. -->
<property name="timeBetweenEvictionRunsMillis" value="15000" />
<!-- The minimum amount of time an object may sit idle in the pool before it is eligible for eviction. -->
<property name="minEvictableIdleTimeMillis" value="60000" />
<property name="removeAbandoned" value="true" />
<property name="removeAbandonedTimeout" value="30" />
<property name="validationQuery" value="SELECT 1" />
<property name="validationInterval" value="30000" />
</bean>
</property>
</bean> <bean id="ucenterSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
<property name="dataSource" ref="dataSource1" />
<property name="mapperLocations" value="classpath:mybatis/mapper/ibs/*/*Dao.xml"></property>
</bean> <bean name="ucenterMapperScannerConfigurer" class="org.mybatis.spring.mapper.MapperScannerConfigurer">
<property name="basePackage" value="com.lime.ibs.*.dao" />
<property name="sqlSessionFactoryBeanName" value="ucenterSessionFactory"></property>
</bean> <bean id="txManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource" ref="dataSource1" />
</bean>
<!-- enable transaction annotation support -->
<tx:annotation-driven transaction-manager="txManager" /> </beans>
能源项目xml文件 -- app-datasource.xml的更多相关文章
- 使用Pull解析器生成XML文件和读取xml文件
有些时候,我们需要生成一个XML文件,生成XML文件的方法有很多,如:可以只使用一个StringBuilder组拼XML内容,然后把内容写入到文件中:或者使用DOM API生成XML文件,或者也可以使 ...
- Maven入门2-pom.xml文件与settings.xml文件
Maven入门2-pom.xml文件与settings.xml文件 本文内容来源于官网文档部分章节,settings.xml文件:参考http://maven.apache.org/settings. ...
- C# 操作XML文件,用XML文件保存信息
using System; using System.Collections.Generic; using System.Text; using System.Xml; using System.IO ...
- java读取xml文件报“org.xml.sax.SAXParseException: Premature end of file” .
背景:java读取xml文件,xml文件内容只有“<?xml version="1.0" encoding="UTF-8"?>”一行 java读取该 ...
- 创建xml文件、解析xml文件
1.创建XML文件: import codecs import xml.dom.minidom doc=xml.dom.minidom.Document() print doc root=do ...
- Java中使用DOM4J来生成xml文件和解析xml文件
一.前言 现在有不少需求,是需要我们解析xml文件中的数据,然后导入到数据库中,当然解析xml文件也有好多种方法,小编觉得还是DOM4J用的最多最广泛也最好理解的吧.小编也是最近需求里遇到了,就来整理 ...
- 【maven】maven创建web项目-pom文件提示web.xml is missing and <failOnMissingWebXml> is set to true
使用maven创建web项目,选择war类型后,pom文件红叉 提示web.xml is missing and <failOnMissingWebXml> is set to true ...
- 创建Xml文件与修改Xml文件
/// <summary> /// 修改节点 /// </summary> /// <param name="user">UserSafe 实体 ...
- Servlet(九):web.xml文件和server.xml文件
Web.xml 文件使用总结:作用: 存储项目相关的配置信息,保护 Servlet.解耦一些数据对程序的依赖.使用位置: 每个 Web 项目中Tomcat 服务器中(在服务器目录 conf 目录中)区 ...
- Android 解析XML文件和生成XML文件
解析XML文件 public static void initXML(Context context) { //can't create in /data/media/0 because permis ...
随机推荐
- Python 主要模块和常用方法简览
******************** PY核心模块方法 ******************** 文件系统功能 os模块 目录: chdir() :改变工作目录 chroot ...
- LNMP(linux+nginx+mysql+php)服务器环境配置
一.简介 Nginx是俄罗斯人编写的十分轻量级的HTTP服务器,Nginx,它的发音为 “engine X”, 是一个高性能的HTTP和反向代理服务器,同时也是一个IMAP/POP3/SMTP 代理服 ...
- white的配置使用
初次使用White来自动化测试10个9相加1.新建Visual C#->测试->单元测试项目2.在资源视图->引用,右键,添加引用,添加White的两个.dll文件3.在工程中添加命 ...
- UVA 10453 十七 Make Palindrome
Make Palindrome Time Limit:3000MS Memory Limit:0KB 64bit IO Format:%lld & %llu Submit St ...
- Java float保留两位小数或多位小数
Java float保留两位小数或多位小数 方法1:用Math.round计算,这里返回的数字格式的. float price=89.89;int itemNum=3;float totalPr ...
- weblogic解密工具
import org.bouncycastle.jce.provider.BouncyCastleProvider; import sun.misc.BASE64Decoder; import jav ...
- Spring Web Flow使用
就当我写(嘘,抄)着玩的. 使用Spring框架的一个子项目--Spring Web Flow来建立和管理Web应用和UI流程. 第一节:使用Spring Web Flow在一个Spring MVC应 ...
- 在Spring中使用脚本
Spring支持3中不同的脚本语言(看来支持地还挺多的嘛):JRuby.Groovy和BeanShell. 这三个都是java社区的脚本语言(反正到目前为止我一个都没用过,可见我有多挫). JRuby ...
- 9.Methods(二)
4.Operator Overload Methods allow a type to define how operators should manipulate instances of the ...
- CUBRID学习笔记 29 web管理中文语言文件 CUBRID教程
网站的中文语言文件部分 http://files.cnblogs.com/files/wang2650/Messages.7z