Refactor DaoAuthenticationProvider cache model.
This commit is contained in:
@@ -152,6 +152,8 @@
|
||||
<lib dir="${lib.dir}/j2ee" includes="jstl.jar"/>
|
||||
<lib dir="${lib.dir}/caucho" includes="*.jar"/>
|
||||
<lib dir="${lib.dir}/jakarta-commons" includes="commons-codec.jar"/>
|
||||
<lib dir="${lib.dir}/jakarta-commons" includes="commons-collections.jar"/>
|
||||
<lib dir="${lib.dir}/ehcache" includes="*.jar"/>
|
||||
<lib dir="${dist.lib.dir}" includes="acegi-security-taglib.jar"/>
|
||||
<lib dir="${dist.lib.dir}" includes="acegi-security.jar"/>
|
||||
</war>
|
||||
|
||||
@@ -48,7 +48,6 @@
|
||||
|
||||
<bean id="daoAuthenticationProvider" class="net.sf.acegisecurity.providers.dao.DaoAuthenticationProvider">
|
||||
<property name="authenticationDao"><ref bean="inMemoryDaoImpl"/></property>
|
||||
<property name="key"><value>my_password</value></property>
|
||||
</bean>
|
||||
|
||||
<bean id="basicProcessingFilter" class="net.sf.acegisecurity.ui.basicauth.BasicProcessingFilter">
|
||||
|
||||
@@ -43,7 +43,11 @@
|
||||
|
||||
<bean id="daoAuthenticationProvider" class="net.sf.acegisecurity.providers.dao.DaoAuthenticationProvider">
|
||||
<property name="authenticationDao"><ref bean="inMemoryDaoImpl"/></property>
|
||||
<property name="key"><value>my_password</value></property>
|
||||
<property name="userCache"><ref bean="userCache"/></property>
|
||||
</bean>
|
||||
|
||||
<bean id="userCache" class="net.sf.acegisecurity.providers.dao.cache.EhCacheBasedUserCache">
|
||||
<property name="minutesToIdle"><value>5</value></property>
|
||||
</bean>
|
||||
|
||||
<!-- Automatically receives AuthenticationEvent messages from DaoAuthenticationProvider -->
|
||||
|
||||
@@ -42,11 +42,14 @@
|
||||
</bean>
|
||||
|
||||
<!-- =================== SECURITY BEANS YOU WILL RARELY (IF EVER) CHANGE ================== -->
|
||||
<!-- However, it is a good idea to change each <property name="key">'s to a new random value -->
|
||||
|
||||
<bean id="daoAuthenticationProvider" class="net.sf.acegisecurity.providers.dao.DaoAuthenticationProvider">
|
||||
<property name="authenticationDao"><ref bean="authenticationDao"/></property>
|
||||
<property name="key"><value>my_password</value></property>
|
||||
<property name="userCache"><ref bean="userCache"/></property>
|
||||
</bean>
|
||||
|
||||
<bean id="userCache" class="net.sf.acegisecurity.providers.dao.cache.EhCacheBasedUserCache">
|
||||
<property name="minutesToIdle"><value>5</value></property>
|
||||
</bean>
|
||||
|
||||
<bean id="authenticationManager" class="net.sf.acegisecurity.providers.ProviderManager">
|
||||
|
||||
Reference in New Issue
Block a user