diff --git a/src/main/java/eu/dnetlib/uoaadmintoolslibrary/UoaAdminToolsLibraryApplication.java b/src/main/java/eu/dnetlib/uoaadmintoolslibrary/UoaAdminToolsLibraryApplication.java deleted file mode 100644 index 86658c9..0000000 --- a/src/main/java/eu/dnetlib/uoaadmintoolslibrary/UoaAdminToolsLibraryApplication.java +++ /dev/null @@ -1,14 +0,0 @@ -package eu.dnetlib.uoaadmintoolslibrary; - -import eu.dnetlib.uoaadmintoolslibrary.configuration.GlobalVars; -import eu.dnetlib.uoaauthorizationlibrary.configuration.AuthorizationConfiguration; -import org.springframework.boot.autoconfigure.SpringBootApplication; -import org.springframework.boot.context.properties.EnableConfigurationProperties; -import eu.dnetlib.uoaadmintoolslibrary.configuration.properties.GoogleConfig; -import eu.dnetlib.uoaadmintoolslibrary.configuration.properties.MailConfig; -import org.springframework.context.annotation.Import; - -@SpringBootApplication//(scanBasePackages = {"eu.dnetlib.uoaauthorizationlibrary"}) -@EnableConfigurationProperties({MailConfig.class, GoogleConfig.class, GlobalVars.class}) -@Import(AuthorizationConfiguration.class) -public class UoaAdminToolsLibraryApplication {} diff --git a/src/main/java/eu/dnetlib/uoaadmintoolslibrary/UoaAdminToolsLibraryConfiguration.java b/src/main/java/eu/dnetlib/uoaadmintoolslibrary/UoaAdminToolsLibraryConfiguration.java index e00aea8..8becdea 100644 --- a/src/main/java/eu/dnetlib/uoaadmintoolslibrary/UoaAdminToolsLibraryConfiguration.java +++ b/src/main/java/eu/dnetlib/uoaadmintoolslibrary/UoaAdminToolsLibraryConfiguration.java @@ -1,14 +1,16 @@ package eu.dnetlib.uoaadmintoolslibrary; -import org.springframework.context.annotation.Bean; +import eu.dnetlib.uoaadmintoolslibrary.configuration.GlobalVars; +import eu.dnetlib.uoaadmintoolslibrary.configuration.properties.GoogleConfig; +import eu.dnetlib.uoaadmintoolslibrary.configuration.properties.MailConfig; +import eu.dnetlib.uoaauthorizationlibrary.configuration.AuthorizationConfiguration; +import org.springframework.boot.context.properties.EnableConfigurationProperties; +import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; -import org.springframework.context.support.PropertySourcesPlaceholderConfigurer; -import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter; +import org.springframework.context.annotation.Import; @Configuration -public class UoaAdminToolsLibraryConfiguration extends WebMvcConfigurerAdapter { - @Bean - public static PropertySourcesPlaceholderConfigurer propertySourcesPlaceholderConfigurer() { - return new PropertySourcesPlaceholderConfigurer(); - } -} \ No newline at end of file +@EnableConfigurationProperties({MailConfig.class, GoogleConfig.class, GlobalVars.class}) +@ComponentScan(basePackages = { "eu.dnetlib.uoaadmintoolslibrary" }) +@Import(AuthorizationConfiguration.class) +public class UoaAdminToolsLibraryConfiguration {} \ No newline at end of file