How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Spring Boot does not create a bean with @ConditionalOnProperty even though the property exists

calendar_today May 28, 2026 person LUIS ANGEL SANTIAGO PALMA domain spring-boot

I am working on a Spring Boot 3 application with Java 17. The app can switch the tree algorithm strategy using a property from application.properties . My application.properties file contains: app.storage=memory app.tree-strategy=custom server.port=8080 This is my configuration class: @Configuration public class TreeStrategyConfig { @Bean @ConditionalOnProperty(name = “app.tree-strategy”, havingValue = “custom”, matchIfMissing = true) public TreeAlgorithmStrategy customTreeStrategy() { return new CustomTreeImpl(); } @Bean @ConditionalOnProperty(name = “app.tree-strategy”, havingValue = “collec

open_in_new Read original post