Fix: propertySoucrces 이동

main
Jooho Yoon 4 years ago
parent 4481cfe088
commit 7ce0cb7d9d

@ -2,6 +2,8 @@ package egovframework.com.config;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.context.annotation.PropertySource;
import org.springframework.context.annotation.PropertySources;
@Configuration
@Import({
@ -15,6 +17,9 @@ import org.springframework.context.annotation.Import;
EgovConfigAppValidator.class,
EgovConfigAppWhitelist.class
})
@PropertySources({
@PropertySource("classpath:/egovframework/egovProps/globals.properties")
}) //CAUTION: min JDK 8
public class EgovConfigApp {
}

@ -7,8 +7,6 @@ import org.apache.commons.dbcp2.BasicDataSource;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;
import org.springframework.context.annotation.PropertySources;
import org.springframework.core.env.Environment;
import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder;
import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseType;
@ -31,11 +29,11 @@ import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseType;
*
*/
@Configuration
@PropertySources({
@PropertySource("classpath:/egovframework/egovProps/globals.properties")
}) //CAUTION: min JDK 8
public class EgovConfigAppDatasource {
/**
* @Value
*/
// @Value("${Globals.DbType}")
// private String dbType;
//
@ -51,6 +49,10 @@ public class EgovConfigAppDatasource {
// @Value("${Globals.Password}")
// private String password;
/**
* Environment
*/
@Autowired
Environment env;

Loading…
Cancel
Save