Example usage for org.springframework.aop.target PoolingConfig getMaxSize

List of usage examples for org.springframework.aop.target PoolingConfig getMaxSize

Introduction

In this page you can find the example usage for org.springframework.aop.target PoolingConfig getMaxSize.

Prototype

int getMaxSize();

Source Link

Document

Return the maximum size of the pool.

Usage

From source file:org.springframework.aop.target.CommonsPoolTargetSourceTests.java

@Test
public void testConfigMixin() {
    SideEffectBean pooled = (SideEffectBean) beanFactory.getBean("pooledWithMixin");
    assertEquals(INITIAL_COUNT, pooled.getCount());
    PoolingConfig conf = (PoolingConfig) beanFactory.getBean("pooledWithMixin");
    // TODO one invocation from setup
    //assertEquals(1, conf.getInvocations());
    pooled.doWork();//from   w  ww  .ja va  2  s  .  c  o  m
    //   assertEquals("No objects active", 0, conf.getActive());
    assertEquals("Correct target source", 25, conf.getMaxSize());
    //   assertTrue("Some free", conf.getFree() > 0);
    //assertEquals(2, conf.getInvocations());
    assertEquals(25, conf.getMaxSize());
}