데이터베이스 설정 수정
parent
56466279d4
commit
a1de2db988
@ -0,0 +1,34 @@
|
||||
package cokr.xit.fims;
|
||||
|
||||
import javax.sql.DataSource;
|
||||
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
|
||||
import cokr.xit.foundation.boot.DatasourceConfig;
|
||||
|
||||
public class DatabaseConfig {
|
||||
public static class FimsDatasource extends DatasourceConfig {
|
||||
@Override
|
||||
@ConfigurationProperties(prefix = "spring.datasource.hikari.fims")
|
||||
public DataSource dataSource() {
|
||||
return super.dataSource();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String[] mapperLocationPatterns() {
|
||||
return new String[] {
|
||||
"classpath*:sql/mapper-jar-applib/base/*.xml",
|
||||
"classpath*:sql/mapper/base/*.xml",
|
||||
"classpath*:sql/mapper/interfaces/*.xml",
|
||||
"classpath*:sql/mapper/fims/**/*.xml",
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String mapperBasePackages() {
|
||||
return "cokr.xit.base;cokr.xit.interfaces;cokr.xit.fims";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
package cokr.xit.fims;
|
||||
|
||||
import org.springframework.boot.autoconfigure.ImportAutoConfiguration;
|
||||
import org.springframework.context.annotation.ComponentScan;
|
||||
import org.springframework.context.annotation.FilterType;
|
||||
|
||||
import cokr.xit.base.boot.XitBaseApplication;
|
||||
import cokr.xit.foundation.boot.DatasourceConfig;
|
||||
|
||||
@ImportAutoConfiguration({
|
||||
DatabaseConfig.FimsDatasource.class
|
||||
})
|
||||
@ComponentScan(
|
||||
excludeFilters = @ComponentScan.Filter(type = FilterType.ASSIGNABLE_TYPE,classes = {DatasourceConfig.class})
|
||||
)
|
||||
public class SpringBootApplicationBridge extends XitBaseApplication {
|
||||
|
||||
}
|
Loading…
Reference in New Issue