Problem autowiring ItemWriter defined with scope="step"
Hi,
I have a problem when I try to @Autowired a bean of type FlatFileItemWriter. I need to calculate a directory name in execution time and assign this value to the "resource" property using late-binding. There's no problem to achive this, but, when my batch runs, I receive an exception when Spring context tries to @Autowired this bean inside my ItemProcessor (I need to use it directly in the ItemProcessor for functional design)
The exception is: There are many candidates of type org.springframework...FlatFileItemWriter.
If I use the @Qualifier then the error refers to another bean that has no sense with that error.
Thanks,