We welcome everyone and thank you in advance for your help.
I am having a problem where Spring cannot autodetect a parameterized member variable of type ArrayBlockingQueue.
Here is the java code:
@Controller public class SomeController { @Autowired private ArrayBlockingQueue<SomeCustomType> myQueue; }
and in Spring xml configuration:
<bean id="myQueue" class="java.util.concurrent.ArrayBlockingQueue"> <constructor-arg value="10"/> </bean>
Setting the type (SomeCustomType) for an ArrayBlockingQueue seems to confuse Spring, which does not find a match and does not auto-increment.
Any ideas on how to make this work? I know that I can create my own wrapper class (around ArrayBlockingQueue) that is not parameterized, but I would prefer if there is a better way to solve this.
source share