DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Haikal has posted 8 posts at DZone. View Full User Profile

Single Connection Data Source Example, With Oracle

  • submit to reddit
        Single Connection Data Source example, with Oracle
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="" xmlns:xsi="" xmlns:p=""
	xmlns:context="" xmlns:tx=""
	<context:property-placeholder location=""/>
	<bean class="oracle.jdbc.driver.OracleDriver" /><!-- Register the driver -->
	<bean id="dataSource" class="org.springframework.jdbc.datasource.SingleConnectionDataSource">
		<constructor-arg value="${jdbc.url}" />
		<constructor-arg value="${jdbc.username}" />
		<constructor-arg value="${jdbc.password}"/>
		<constructor-arg value="true"/> <!-- suppress close -->