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 3 fails to find bean despite @Service annotation and correct package structure

calendar_today July 9, 2026 person gilson_leonel01 domain spring-boot

I have a Spring Boot 3 application where a controller depends on a service annotated with @Service , but the application fails to start because Spring cannot find the OrderService bean. Error Field orderService in com.mycompany.app.controller.OrderController required a bean of type ‘com.mycompany.app.service.OrderService’ that could not be found. Project structure src/main/java/com/mycompany/app/ ├── Application.java ├── controller/ │ └── OrderController.java └── service/ └── OrderService.java Application.java package com.mycompany.app; import org.springframework.boot.SpringApplication; import

open_in_new Read original post