Not sure I understand the question, but creating threads and beans are not related exactly. For instance the following will create a thread per each Spring singleton:
Code:
<beans>
<bean id="thread1" class="Threader" init-method="init">
<property name="title" value="x"/>
</bean>
<bean id="thread2" class="Threader" init-method="init">
<property name="title" value="y"/>
</bean>
</beans>
public class Threader extends Thread {
private String title;
public void run() {
while(true){
System.out.println("Running..." + this.currentThread().getName());
}
}
public void init(){
Threader t = new Threader();
t.setName(getTitle());
t.start();
}
....
}
**** post edit ****
Of course, Spring may have an easier way of doing this. Or, you can just use Spring scheduling.