Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: 黄小虎 <[email protected]>
  • Loading branch information
velna committed Sep 27, 2013
1 parent 1a9cbe6 commit f2a77fd
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 2 deletions.
10 changes: 8 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -113,16 +113,19 @@
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<version>3.1.2.RELEASE</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-orm</artifactId>
<artifactId>spring-tx</artifactId>
<version>3.1.2.RELEASE</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-tx</artifactId>
<artifactId>spring-orm</artifactId>
<version>3.1.2.RELEASE</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>log4j</groupId>
Expand Down Expand Up @@ -182,11 +185,13 @@
<groupId>org.hibernate</groupId>
<artifactId>hibernate-core</artifactId>
<version>4.1.6.Final</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-entitymanager</artifactId>
<version>4.1.6.Final</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.mongodb</groupId>
Expand All @@ -198,6 +203,7 @@
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.21</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
package org.sothis.core.config;

import java.io.IOException;
import java.util.Properties;

import org.sothis.core.config.PropertiesBean;
import org.springframework.beans.factory.config.PropertyPlaceholderConfigurer;
import org.springframework.util.CollectionUtils;

public class SpringPropertyPlaceholderConfigurer extends PropertyPlaceholderConfigurer implements PropertiesBean {

private Properties properties;
private PropertiesBean propertiesBean;

@Override
protected Properties mergeProperties() throws IOException {
properties = super.mergeProperties();
CollectionUtils.mergePropertiesIntoMap(propertiesBean.getProperties(), properties);
return properties;
}

public Properties getProperties() {
return properties;
}

public void setPropertiesBean(PropertiesBean propertiesBean) {
this.propertiesBean = propertiesBean;
}

}
8 changes: 8 additions & 0 deletions sothis-dal/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,14 @@
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-tx</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-orm</artifactId>
</dependency>
<dependency>
<groupId>org.mongodb</groupId>
<artifactId>mongo-java-driver</artifactId>
Expand Down

0 comments on commit f2a77fd

Please sign in to comment.