In alfresco , i want to retrieve all data using a webscript that has a cmis query.
for small folders i am getting the data
but for large folders, the data is not getting fetched.
this is maybe due to system.acl.maxPermissionCheckTimeMillis and system.acl.maxPermissionCheck in the repository.properties file.
What is the maximum value that can be set for these two properties ?
Thanks
Solved! Go to Solution.
The maximum value is determined by the Java type used for these properties. "maxPermissionCheckTimeMillis" is a long and "maxPermissionCheck" is an int, so the limits are 2^63 - 1 and 2^31 - 1 respectively.
You should never have to change these settings though - it is always recommended to fetch reasonably sized extracts of a larger search result and use pagination if you need additional data. At a certain amount of results loaded in a single operation - depending on the configuration of caches - you will also run into issues with transactional cache sizes being too small, causing unconditional clearance of global caches which will tank system performance.
The maximum value is determined by the Java type used for these properties. "maxPermissionCheckTimeMillis" is a long and "maxPermissionCheck" is an int, so the limits are 2^63 - 1 and 2^31 - 1 respectively.
You should never have to change these settings though - it is always recommended to fetch reasonably sized extracts of a larger search result and use pagination if you need additional data. At a certain amount of results loaded in a single operation - depending on the configuration of caches - you will also run into issues with transactional cache sizes being too small, causing unconditional clearance of global caches which will tank system performance.
yes you are right i am getting warnings in the log like below:-
WARN [org.alfresco.repo.cache.TransactionalCache.org.alfresco.cache.node.nodesTransactionalCache] Transactional update cache 'org.alfresco.cache.node.nodesTransactionalCache' is full (50000).
are there any tutorial for pagination for a js based webscript ?
Also i am getting this error inconsistently:-
Caused by: org.mozilla.javascript.EcmaError: TypeError: Cannot read property "length" from null
how to resolve this ?
i am using alfresco version 3.4
Thank you
Oh wow - that is a somewhat "ancient" version of Alfresco.
You can learn about JavaScript search pagination in the documentation of the "search" root scope object and its "query" operation. But you will not avoid the issue with the transactional cache by doing multiple paginated queries in one ReST API call - you should adapt the client to call the web script each time you want to load the next page of results.
The EcmaError is a very generic error pointing you to a programming error in your script. You are trying to get the "length" property of an object / string / array that may be null. You should check that against null before you access that property.
Ask for and offer help to other Alfresco Content Services Users and members of the Alfresco team.
Related links:
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.