For stateful session bean you can specify the cache details in weblogic-ejb-jar.xml file:
<?xml version="1.0"?><!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB//EN'
'http://www.bea.com/servers/wls600/dtd/weblogic-ejb-jar.dtd'><weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>BEAN_NAME_AS_DEFINED_IN_EJB_JAR_D</ejb-name>
<stateful-session-descriptor>
<stateful-session-cache>
<max-beans-in-cache>2</max-beans-in-cache>
<idle-timeout-seconds>100</idle-timeout-seconds>
<cache-type>LRU</cache-type>
</stateful-session-cache>
</stateful-session-descriptor>
<jndi-name>MY_JNDI_NAME</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
Since stateful session bean is created for every client there is no pooling associated with it instead welogic provides cache facility. Please refer to the stateful-session-descriptor documentation in weblogic
ejb guide for more details.
Thanks.