From a7ea6c8a826a9a1571666218c1b55afb91117a2a Mon Sep 17 00:00:00 2001 From: eugenp Date: Sun, 5 May 2013 21:21:30 +0300 Subject: [PATCH] mainly doc work --- spring-hibernate3-dao/README.md | 2 +- .../baeldung/spring/persistence/config/PersistenceConfig.java | 4 ++-- spring-hibernate4-dao/README.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/spring-hibernate3-dao/README.md b/spring-hibernate3-dao/README.md index afb2185d60..89dd04db82 100644 --- a/spring-hibernate3-dao/README.md +++ b/spring-hibernate3-dao/README.md @@ -1,3 +1,3 @@ -Spring MVC with Java Configuration +Hibernate 3 with Spring ========= diff --git a/spring-hibernate3-dao/src/main/java/org/baeldung/spring/persistence/config/PersistenceConfig.java b/spring-hibernate3-dao/src/main/java/org/baeldung/spring/persistence/config/PersistenceConfig.java index e8f448f4c2..b59ea8e341 100644 --- a/spring-hibernate3-dao/src/main/java/org/baeldung/spring/persistence/config/PersistenceConfig.java +++ b/spring-hibernate3-dao/src/main/java/org/baeldung/spring/persistence/config/PersistenceConfig.java @@ -33,7 +33,7 @@ public class PersistenceConfig { @Bean public AnnotationSessionFactoryBean sessionFactory() { final AnnotationSessionFactoryBean sessionFactory = new AnnotationSessionFactoryBean(); - sessionFactory.setDataSource(restDataSource()); + sessionFactory.setDataSource(dataSource()); sessionFactory.setPackagesToScan(new String[] { "org.baeldung.spring.persistence.model" }); sessionFactory.setHibernateProperties(hibernateProperties()); @@ -41,7 +41,7 @@ public class PersistenceConfig { } @Bean - public DataSource restDataSource() { + public DataSource dataSource() { final DriverManagerDataSource dataSource = new DriverManagerDataSource(); dataSource.setDriverClassName(Preconditions.checkNotNull(env.getProperty("jdbc.driverClassName"))); dataSource.setUrl(Preconditions.checkNotNull(env.getProperty("jdbc.url"))); diff --git a/spring-hibernate4-dao/README.md b/spring-hibernate4-dao/README.md index afb2185d60..12eb079c88 100644 --- a/spring-hibernate4-dao/README.md +++ b/spring-hibernate4-dao/README.md @@ -1,3 +1,3 @@ -Spring MVC with Java Configuration +Hibernate 4 with Spring =========