Can I negate (!) a collection of spring profiles?

Since Spring 5.1 (incorporated in Spring Boot 2.1) it is possible to use a profile expression inside profile string annotation (see the description in Profile.of(..) for details). So to exclude your bean from certain profiles you can use an expression like this: @Profile(“!dev & !prof1 & !prof2”) Other logical operators can be used as well, … Read more

application context. What is this?

@feak gives a straight answer about the meaning of ApplicationContext in terms of Spring. In short, it is an object that loads the configuration (usually a XML file annotation based) and then Spring will start managing the beans and its benefits: Beans declared in package Beans declared by annotations Constructor and method autowiring Bean injection … Read more