Hello Jeff,

For you problem, take a look at
org.jboss.ejb.plugins.AbstractInstancePool.get():

    public synchronized EnterpriseContext get()
    throws Exception
    {
        //DEBUG      Logger.debug("Get instance "+this);

        if (!pool.empty())
        {
         mReadyBean.remove();
            return (EnterpriseContext)pool.pop();
        } else
        {
            try
            {
                return create(container.createBeanClassInstance());
            } catch (InstantiationException e)
            {
                throw new ServerException("Could not instantiate bean", e);
            } catch (IllegalAccessException e)
            {
                throw new ServerException("Could not instantiate bean", e);
            }
        }
    }


As you can see, with this implementation, JBoss has a goal: to serve each
request immediately. Consequently, if the pool is empty, a new instance is
created and, once the instance is returned to the pool, the instance will be
freed (and not returned back to the pool). Thus, JBoss don't wait for an
instance to become available to serve concurrent requests.

        => the pool size will never exceed the size you indicate in your deployment
descriptor *but* the number of active instances *may* be bigger if
concurrent acccess require it.

> What am I messing ?!! Please help.... As I have bean
> struggling with this kind of a problem for over a month
> now.

And in 10 seconds of JBoss consulting you have your answer ;)

Cheers,



                                Sacha


_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to