Standby Ajb does not delete pool

I have problems with memory leaks because EJBs are not removed from the pool. Ajb is 3.0 and stateless.

In my jboss jmx-console 4.3, the statistics of a particular ejb looks like: AvailableCount 30 MaxSize 30 CurrentSize 5727 CreateCount 5727 RemoveCount 0 

My question is: why does โ€œDelete Accountโ€ not increase? And is "Current Size" bigger than "MaxSize"?

+6
source share
1 answer

The person you fell into a terrible mistake when the SLSBs were not cleaned and leaked ... We encountered this problem in our production environment a couple of weeks ago ...

The only workaround even recommended by JBoss is to use StrictMaxPool instead of ThreadLocalPool for your SLSB. Choose an account wisely.

You should change ejb3-interceptors-aop.xml

 <domain name="Stateless Bean"> ... <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)"> @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000) </annotation> </domain> 

Here are some links to give you some insight ...

A stalled bean merge session in JBoss

A new instance of resources that is entered with every MDB call for MDMage

ThreadlocalPool does not remove active BeanContext instances from InfinitePool

+3
source

Source: https://habr.com/ru/post/923154/


All Articles