@Autowired
is sometimes handy even though constructor injection is preferred sometimes. Lombok's @RequiredArgsConstructor
is often used with constructor injection.
@Qualifier("nameOfBean")
helps when fetching a bean that has been named with the (name="nameOfBean")
parameter to an annotation. There's an example in
Antkorwin's spring state machine (SSM) notes