Hi
I want to have a pool of objects and instantiate them all when I deploy the application.

Here is the xml snippet where I declare the target bean, the pool and the proxy.

Code:
<bean id="myTargetBean" class="package.TargetBean" scope="prototype" lazy-init="false">
</bean>

<bean id="targetBeanPool" class="org.springframework.aop.target.CommonsPoolTargetSource" lazy-init="false">
  <property name="targetBeanName" value="myTargetBean" />
  <property name="minIdle" value="100" />
</bean>

<bean id="myPoolFactory" class="org.springframework.aop.framework.ProxyFactoryBean">
  <property name="targetSource" ref="targetBeanPool" />
</bean>
Below part of the code of the targetBean. Because I need some autowired stuff in the constructor, I used the @PostConstructor method

Code:
public class TargetBean {
  private Client client;

  @PostConstruct
  private void postConstructor(){
    //Some stuff

    log.debug("client instanciated : "+client);
  }

  public Client getClient() { return client; }
}
and ultimately, elsewhere in the code, I autowire the proxy to get the pooled objects.
Code:
@Autowired
TargetBean myPoolFactory;

Client client = myPoolFactory.getClient();
This code works fine except that only one TargetBean is created when I start the application. I though minIdle would have solved the problem but apparently not.
What did I miss ?
Thanks