java - Assign a pool to a specific stateless bean in JBoss EAP 6.1 -


i can see how 1 can control size of global pool stateless session beans.

however, able have new pool applies 1 type of stateless bean. way, stateless beans 1 pooled usual slsb-strict-max-pool, , 1 bean have own pool.

is possible in jboss eap 6.1?

use

@org.jboss.ejb3.annotation.pool(value="mypoolname") 

annotation on ejb referencing custom pool defined in standalone.xml :

<pools>      <bean-instance-pools>                 <strict-max-pool name="slsb-strict-max-pool"                                  max-pool-size="20" instance-acquisition-timeout="5"                                  instance-acquisition-timeout-unit="minutes" />                 <strict-max-pool name="mdb-strict-max-pool"                                  max-pool-size="80" instance-acquisition-timeout="1"                                  instance-acquisition-timeout-unit="minutes" />                 <strict-max-pool name="mypoolname"                                  max-pool-size="20" instance-acquisition-timeout="5"                                  instance-acquisition-timeout-unit="seconds" />             </bean-instance-pools> </pools> 

[edit] without annotation :

using pool namespace (urn:ejb-pool:1.0) in jboss-ejb3.xml (jboss specific ejb descriptor)

<p:pool>  <ejb-name>myejbname</ejb-name>  <p:bean-instance-pool-ref>mypoolname</p:bean-instance-pool-ref> </p:pool> 

Comments

Popular posts from this blog

database - VFP Grid + SQL server 2008 - grid not showing correctly -

jquery - Set jPicker field to empty value -

.htaccess - htaccess convert request to clean url and add slash at the end of the url -