mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Fix AR-350: Transactional caches for node ownership and permissions statuses
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2354 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
</bean>
|
||||
|
||||
<!-- ================ -->
|
||||
<!-- Null permissoins -->
|
||||
<!-- Null permissions -->
|
||||
<!-- ================ -->
|
||||
|
||||
<!-- The cross-transaction shared cache for Null Node Permissions -->
|
||||
@@ -25,6 +25,12 @@
|
||||
<!-- The name of the ehCache area -->
|
||||
<value>nullPermissionCache</value>
|
||||
</property>
|
||||
<property name="maxElementsInMemory">
|
||||
<value>10000</value>
|
||||
</property>
|
||||
<property name="overflowToDisk">
|
||||
<value>false</value>
|
||||
</property>
|
||||
</bean>
|
||||
</property>
|
||||
</bean>
|
||||
@@ -43,7 +49,7 @@
|
||||
<value>nullPermissionTransactionalCache</value>
|
||||
</property>
|
||||
<property name="maxCacheSize">
|
||||
<value>20000</value>
|
||||
<value>5000</value>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
@@ -51,7 +57,7 @@
|
||||
<!-- Authority container look up for users -->
|
||||
<!-- ===================================== -->
|
||||
|
||||
<!-- The cross-transaction shared cache for Users -->
|
||||
<!-- The cross-transaction shared cache for User Authorities -->
|
||||
|
||||
<bean name="userToAuthoritySharedCache" class="org.alfresco.repo.cache.EhCacheAdapter">
|
||||
<property name="cache">
|
||||
@@ -60,11 +66,17 @@
|
||||
<!-- The name of the ehCache area -->
|
||||
<value>userToAuthorityCache</value>
|
||||
</property>
|
||||
<property name="maxElementsInMemory">
|
||||
<value>10000</value>
|
||||
</property>
|
||||
<property name="overflowToDisk">
|
||||
<value>false</value>
|
||||
</property>
|
||||
</bean>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- The transactional cache for Null Node Permissions -->
|
||||
<!-- The transactional cache for User Authorities -->
|
||||
|
||||
<bean name="userToAuthorityCache" class="org.alfresco.repo.cache.TransactionalCache">
|
||||
<property name="sharedCache">
|
||||
@@ -78,7 +90,89 @@
|
||||
<value>userToAuthorityTransactionalCache</value>
|
||||
</property>
|
||||
<property name="maxCacheSize">
|
||||
<value>20000</value>
|
||||
<value>5000</value>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- ===================================== -->
|
||||
<!-- Permissions access cache -->
|
||||
<!-- ===================================== -->
|
||||
|
||||
<!-- The cross-transaction shared cache for Permissions -->
|
||||
|
||||
<bean name="permissionsAccessSharedCache" class="org.alfresco.repo.cache.EhCacheAdapter">
|
||||
<property name="cache">
|
||||
<bean class="org.springframework.cache.ehcache.EhCacheFactoryBean" >
|
||||
<property name="cacheName">
|
||||
<!-- The name of the ehCache area -->
|
||||
<value>permissionsAccessCache</value>
|
||||
</property>
|
||||
<property name="maxElementsInMemory">
|
||||
<value>10000</value>
|
||||
</property>
|
||||
<property name="overflowToDisk">
|
||||
<value>false</value>
|
||||
</property>
|
||||
</bean>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- The transactional cache for Permissions -->
|
||||
|
||||
<bean name="permissionsAccessCache" class="org.alfresco.repo.cache.TransactionalCache">
|
||||
<property name="sharedCache">
|
||||
<ref bean="permissionsAccessSharedCache" />
|
||||
</property>
|
||||
<property name="cacheManager" >
|
||||
<ref bean="ehCacheManager" />
|
||||
</property>
|
||||
<!-- Eh cache area -->
|
||||
<property name="name">
|
||||
<value>permissionsAccessTransactionalCache</value>
|
||||
</property>
|
||||
<property name="maxCacheSize">
|
||||
<value>5000</value>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- ===================================== -->
|
||||
<!-- Node owner cache -->
|
||||
<!-- ===================================== -->
|
||||
|
||||
<!-- The cross-transaction shared cache for Node Ownership -->
|
||||
|
||||
<bean name="nodeOwnerSharedCache" class="org.alfresco.repo.cache.EhCacheAdapter">
|
||||
<property name="cache">
|
||||
<bean class="org.springframework.cache.ehcache.EhCacheFactoryBean" >
|
||||
<property name="cacheName">
|
||||
<!-- The name of the ehCache area -->
|
||||
<value>nodeOwnerCache</value>
|
||||
</property>
|
||||
<property name="maxElementsInMemory">
|
||||
<value>10000</value>
|
||||
</property>
|
||||
<property name="overflowToDisk">
|
||||
<value>false</value>
|
||||
</property>
|
||||
</bean>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- The transactional cache for Node Ownership -->
|
||||
|
||||
<bean name="nodeOwnerCache" class="org.alfresco.repo.cache.TransactionalCache">
|
||||
<property name="sharedCache">
|
||||
<ref bean="nodeOwnerSharedCache" />
|
||||
</property>
|
||||
<property name="cacheManager" >
|
||||
<ref bean="ehCacheManager" />
|
||||
</property>
|
||||
<!-- Eh cache area -->
|
||||
<property name="name">
|
||||
<value>nodeOwnerTransactionalCache</value>
|
||||
</property>
|
||||
<property name="maxCacheSize">
|
||||
<value>5000</value>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
|
@@ -9,5 +9,8 @@
|
||||
<property name="authenticationService">
|
||||
<ref bean="authenticationServiceImpl"/>
|
||||
</property>
|
||||
<property name="nodeOwnerCache">
|
||||
<ref bean="nodeOwnerCache"/>
|
||||
</property>
|
||||
</bean>
|
||||
</beans>
|
@@ -63,6 +63,9 @@
|
||||
<property name="authorityService">
|
||||
<ref bean="authorityService" />
|
||||
</property>
|
||||
<property name="accessCache">
|
||||
<ref bean="permissionsAccessCache" />
|
||||
</property>
|
||||
<!-- Dynamic authorites are evaluated in the context of a store/node etc -->
|
||||
<!-- as opposed to being fixed like user name and groups. -->
|
||||
<!-- There are two dynamic authorities, the ower of a node and the owner -->
|
||||
|
@@ -3,7 +3,7 @@
|
||||
path="java.io.tmpdir"/>
|
||||
<defaultCache
|
||||
maxElementsInMemory="5000"
|
||||
eternal="false"
|
||||
eternal="true"
|
||||
timeToIdleSeconds="0"
|
||||
timeToLiveSeconds="0"
|
||||
overflowToDisk="false"
|
||||
|
Reference in New Issue
Block a user