* BAEL-2569 : EnvironmentPostProcessor in Spring Boot

* BAEL-2569 add test

* BAEL-2569 update test

* BAEL-2569  refactoring the class PriceCalculationEnvironmentPostProcessor

* BAEL-2569: changes to class PriceCalculationEnvironmentPostProcessor

* BAEL-2569 move code to spring-boot-ops module
This commit is contained in:
letcodespeak 2019-04-08 01:51:00 +10:00 committed by maibin
parent 9ffec6819c
commit b9d34bfc7a
10 changed files with 7 additions and 6 deletions

View File

@ -35,7 +35,7 @@ public class PriceCalculationApplication implements CommandLineRunner {
int quantity = Integer.valueOf(params.get(1));
priceCalculationService.productTotalPrice(singlePrice, quantity);
} else {
logger.error("Invalid arguments " + params.toString());
logger.warn("Invalid arguments " + params.toString());
}
}

View File

@ -0,0 +1,6 @@
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
com.baeldung.environmentpostprocessor.autoconfig.PriceCalculationAutoConfig
org.springframework.boot.env.EnvironmentPostProcessor=\
com.baeldung.environmentpostprocessor.PriceCalculationEnvironmentPostProcessor

View File

@ -1,7 +1,2 @@
org.springframework.boot.diagnostics.FailureAnalyzer=com.baeldung.failureanalyzer.MyBeanNotOfRequiredTypeFailureAnalyzer
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
com.baeldung.environmentpostprocessor.autoconfig.PriceCalculationAutoConfig
org.springframework.boot.env.EnvironmentPostProcessor=\
com.baeldung.environmentpostprocessor.PriceCalculationEnvironmentPostProcessor