스프링부트

Spring @Component vs @Bean

jinaenya 2025. 3. 12. 16:17

https://stackoverflow.com/questions/10604298/spring-component-versus-bean

 

Spring: @Component versus @Bean

I understand that @Component annotation was introduced in Spring 2.5 to get rid of XML bean definition by using classpath scanning. @Bean was introduced in spring 3.0 and can be used with @Configur...

stackoverflow.com

https://velog.io/@martindog/Spring-Component-vs-Bean

 

[Spring] @Component vs @Bean

클래스에 붙는 어노테이션으로 스프링 프레임워크에서 관리할 클래스임을 나타내는 것이다.한국어로 하면 의존성으로 한클래스가 다른 클래스에 의존하고 있는것EX) A가 B를 의존하고 있다Compon

velog.io