cancel
Showing results for 
Search instead for 
Did you mean: 

why is the Transactional update cache full

malcolmc
Champ on-the-rise
Champ on-the-rise
Hi All,
I am trying to add some functionality to an existing plugin available on github.

The plugin finds all nodes available under a parent node by calling the findAllNodes function which recursively builds a list of all nodes found.

My issue is when this function is executed against a node that has a high number of nodes, for instance a site node with 74556 child nodes, the below code causes the transaction caches to fill up in alfresco.

I do not understand how the below code is using the transaction cache, so I am sure how to fix the issue.

Does any one understand why the below code would cause the warnings shown below:

thanks for reading.
malcolm

2015-12-09 14:34:20,566  WARN  [alfresco.cache.contentUrlTransactionalCache] [http-apr-8080-exec-1] Transactional update cache 'org.alfresco.cache.contentUrlTransactionalCache' is full (65000).
2015-12-09 14:34:42,919  WARN  [org.alfresco.nodeOwnerTransactionalCache] [http-apr-8080-exec-1] Transactional update cache 'org.alfresco.nodeOwnerTransactionalCache' is full (40000).
2015-12-09 14:37:53,374  WARN  [cache.node.nodesTransactionalCache] [http-apr-8080-exec-1] Transactional update cache 'org.alfresco.cache.node.nodesTransactionalCache' is full (125000).
2015-12-09 14:38:04,447  WARN  [cache.node.aspectsTransactionalCache] [http-apr-8080-exec-1] Transactional update cache 'org.alfresco.cache.node.aspectsTransactionalCache' is full (65000).
2015-12-09 14:38:04,480  WARN  [cache.node.propertiesTransactionalCache] [http-apr-8080-exec-1] Transactional update cache 'org.alfresco.cache.node.propertiesTransactionalCache' is full (65000).
2015-12-09 14:38:29,495  WARN  [alfresco.cache.contentDataTransactionalCache] [http-apr-8080-exec-1] Transactional update cache 'org.alfresco.cache.contentDataTransactionalCache' is full (65000).

    /**          * Recursive find of all item head nodes from a given node ref     *      * @param nodeRef     */    public List<NodeRef> findAllNodes(NodeRef nodeRef) throws Exception     {        List<NodeRef> nodes = new ArrayList<NodeRef>();                if(!this.dao.isNodeIgnored(nodeRef.toString()))        {                if(this.dao.isFolder(nodeRef))            {                nodes.add(nodeRef); // add folder as well                List<NodeRef> children= this.dao.getChildren(nodeRef);                for (NodeRef child : children)                {                                nodes.addAll(this.findAllNodes(child));                }            }            else             {                   nodes.add(nodeRef);            }           }                                   return nodes;    }           /**          * The following functions are part of the dao class as referenced from above     */        public boolean isNodeIgnored(String nodeRef)    {        log.debug("isNodeIgnored");        NodeRef nr = getNodeRef(nodeRef);                QName value = nodeService.getType(nr);                log.debug("isNodeIgnored got service type");        return isTypeIgnored(value);    }    public boolean isFolder(NodeRef nodeRef) throws Exception    {           FileInfo info = service.getFileInfo(nodeRef);        return info.isFolder();    }    public List<NodeRef> getChildren(NodeRef nodeRef) throws Exception    {           List<NodeRef> listChildren = new ArrayList<NodeRef>();                List<ChildAssociationRef> children = nodeService.getChildAssocs(nodeRef);                for (ChildAssociationRef childAssociationRef : children)        {            NodeRef child = childAssociationRef.getChildRef();                            if(this.isTypeIgnored(nodeService.getType(child)))            {                continue;            }            listChildren.add(new NodeRef(child.toString())); // deep copy        }        return listChildren;    }‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍

1 REPLY 1

hiten_rastogi1
Star Contributor
Star Contributor

Hey,

Any chance that you were able to figure out what is the issue here. As we also facing the same issue.