Here are some common interview questions for the Spring Core module:
- Can you explain the concept of Inversion of Control (IoC) in Spring?
- What is Dependency Injection (DI) and how does it relate to IoC in Spring?
- Can you describe the different types of DI in Spring?
- How does Spring manage bean dependencies?
- Can you explain the role of the ApplicationContext in Spring?
- What is the difference between the ApplicationContext and the BeanFactory in Spring?
- Can you explain the use of the @Autowired annotation in Spring?
- How does the @Qualifier annotation work in Spring?
- Can you explain the role of the @ComponentScan annotation in Spring?
- What is the purpose of the @Bean annotation in Spring?
- Can you explain the use of the @Value annotation in Spring?
- How would you configure a bean in Spring using XML configuration?
- Can you explain the use of the @Configuration and @Bean annotations for bean configuration in Spring?
- How does the @Profile annotation work in Spring?
- Can you explain the use of the @Primary annotation in Spring?
- Can you describe the lifecycle of a bean in Spring?
- Can you explain the use of the @PostConstruct and @PreDestroy annotations in Spring?
- Can you describe the BeanPostProcessor interface in Spring and how it is used?
- Can you explain the use of the @Scope annotation in Spring and the different scopes available?
- Can you explain the use of the @Lazy annotation in Spring?
- Can you describe the role of the PropertyEditor in Spring?
- Can you explain the use of the ConversionService in Spring?
- How does the Resource abstraction work in Spring and what are the different types of Resource implementations available?
- Can you explain the use of the @PropertySource annotation in Spring?
- Can you explain the use of the Environment interface in Spring and how it is used to access properties?
- Can you explain the use of the @Value with SpEL (Spring Expression Language) in Spring?
- Can you explain the use of the @Order annotation in Spring?
- Can you explain the use of the @Import annotation in Spring?
- Can you describe the use of the @ImportResource annotation in Spring?
- Can you explain the use of Aspect Oriented Programming (AOP) in Spring?
- Can you describe the role of the @Aspect annotation in Spring AOP?
- Can you explain the use of the @Pointcut annotation in Spring AOP?
- Can you explain the use of the @Before, @After, @Around annotations in Spring AOP?
- Can you explain how you would use AOP to implement logging in a Spring application?
- Can you describe the use of the @Transactional annotation in Spring and how it works?
- Can you explain the different transaction propagation modes in Spring?
- Can you explain the use of the PlatformTransactionManager interface in Spring?
- Can you describe the use of the JdbcTemplate class in Spring and how it is used for database access?
- Can you explain the use of the NamedParameterJdbcTemplate class in Spring and how it is used for database access with named parameters?
- Can you describe the use of the SimpleJdbcInsert and SimpleJdbcCall classes in Spring for database access?
- Can you explain the use of the ApplicationContext in Spring and the different types of ApplicationContext implementations?
- Can you explain the difference between ApplicationContext and BeanFactory in Spring?
- Can you explain the use of the @Autowired and @Qualifier annotations in Spring for dependency injection?
- Can you describe the use of the @Resource annotation in Spring for dependency injection?
- Can you explain the use of the @Primary annotation in Spring for dependency injection?
- Can you explain the use of the @Profile annotation in Spring for profile-based bean configuration?
- Can you explain the use of the @Conditional annotation in Spring for conditional bean configuration?
- Can you explain the use of the @Service and @Repository annotations in Spring?
- Can you explain the use of the @Controller and @RestController annotations in Spring for web applications?
- Can you describe the role of the DispatcherServlet and ContextLoaderListener in a Spring MVC web application?
