Top "Spring-ioc" questions

The Spring IoC is a core component of the Spring Framework.

exclude @Component from @ComponentScan

I have a component that I want to exclude from a @ComponentScan in a particular @Configuration: @Component("foo") class Foo { ... } …

java spring dependency-injection spring-boot spring-ioc
Spring default behavior for lazy-init

I am beginner to spring, ESP Inversion of control. I was puzzled understanding the difference between the following <bean …

spring spring-ioc
Is spring default scope singleton or not?

Could you please explain why Spring is creating two objects for the configuration of beans shown below, since by default …

java spring dependency-injection singleton spring-ioc
Spring bean scopes: session and globalSession

What is the difference between session and globalSession in Spring framework? <bean id="exampleBean" class="com.test.baen.ExampleBean" …

java spring spring-mvc spring-ioc
How to avoid using ApplicationContext.getBean() when implementing Spring IOC

I'm just getting started with Spring IOC concept. I often see most of the examples found in the internet use …

java spring jakarta-ee inversion-of-control spring-ioc
Spring dependency issue - no matching editors or conversion strategy found

I have a web application which fails while deployment. I get following error: Aug 8, 2014 7:00:21 PM org.springframework.web.context.ContextLoader …

java spring spring-security spring-ioc
Proper way to inject parent class dependencies with Spring annotations

I have following code - Dao.java @Component public class Dao extends NamedParameterJdbcDaoSupport { } dbContext.xml <bean id="dataSource" class="…

java spring inversion-of-control spring-ioc
Spring Boot: autowire beans from library project

I'm struggling to autowire beans from my custom library, imported with gradle. after reading couple of similar topics I am …

spring-boot spring-data-jpa multi-module spring-ioc component-scan
Spring bean map with dynamic keys and values

Right now i've application related data in spring bean map and passed this map to other classes as ref. Map …

java spring hashmap spring-ioc
Difference between @injectMocks and @Autowired usage in mockito?

When I was writing test case using the Mockito and Junit, I was using the @InjectMocks for the class to …

java spring dependency-injection mockito spring-ioc