This discussion is archived
3 Replies Latest reply: Nov 20, 2012 11:36 PM by r035198x RSS

CacheFullException: cache size after cleaning

975010 Newbie
Currently Being Moderated
Hello, all.
I need you help. Unfortunately, because of i am a new in Java, my question may be a bit stupid and incorrectly formulated—é
I have an exception:
2012-10-15 11:09:01,293 ERROR [[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'] ( /se.netwise.mcx.web.DispatcherServlet/ - An error occurred when trying to dispatch GET action: /McxOwu/listCompanies.action
java.rmi.RemoteException: EJB Exception: ; nested exception is: 
     javax.ejb.EJBException: Exception in ejbLoad:: weblogic.ejb20.cache.CacheFullException: cache size after cleaning=4001, max allowable cache size=4000, extra free space required but not obtainable = 1
     at weblogic.ejb.container.cache.EntityCache$SizeTracker.acquireSpace(
     at weblogic.ejb.container.cache.EntityCache.put(
     at weblogic.ejb.container.manager.DBManager.getReadyBean(
     at weblogic.ejb.container.manager.DBManager.preInvoke(
     at weblogic.ejb.container.internal.BaseLocalObject.preInvoke(
     at weblogic.ejb.container.internal.BaseLocalObject.preInvokeLite(
     at weblogic.ejb.container.internal.EntityEJBLocalObject.preInvokeLite(
     at se.netwise.mcx.domainservice.entity.ejb.CompanyBean_3rx9vq_ELOImpl.getCompanyId(
     at se.netwise.mcx.domainservice.dao.CompanyDAO.getCompaniesForServiceProviderWithFilters(
when i trying to upload info from DB to Entity Cache. I know that it's not a good way for this issue, but it was not me who developed this product. I should solve it.
An exception happens in this code
public CompanyTO[] getCompaniesForServiceProvider(String serviceProviderId)
          throws DomainFinderException {
     Collection companies;
     try {
          companies = CompanyBeanUtil.getLocalHome()
          } catch (FinderException e) {
          if (e instanceof ObjectNotFoundException) {
               throw new DomainFinderException();
          throw new DomainSysException();
     } catch (NamingException e) {
          throw new DomainSysException(e.getMessage());
     ArrayList<CompanyTO> companyTOList = new ArrayList(companies.size());
     CompanyBeanLocal local;
     for (Iterator iter = companies.iterator(); iter.hasNext();) {
          local = (CompanyBeanLocal);
          companyTOList.add(new CompanyTO(local.getCompanyId(), local.getCompanyName(), local.getCompanyBillingNumber()));
     return (CompanyTO[]) companyTOList.toArray(new CompanyTO[0]);
in this line:
companyTOList.add(new CompanyTO(local.getCompanyId(), local.getCompanyName(), local.getCompanyBillingNumber()));

So i want to delete local object from Entity cache after adding it to my Array. But i don't how to do it.
I found method EntityCache.remove:

public void remove(java.lang.Object arg0, weblogic.ejb.container.cache.CacheKey arg1);

but what is arg0 and arg1, how to obtain it?


Edited by: 972007 on Nov 19, 2012 7:30 AM

Edited by: 972007 on Nov 19, 2012 7:30 AM


  • Correct Answers - 10 points
  • Helpful Answers - 5 points