Merged 5.0.2-CLOUD42 (Cloud ) to 5.1.N (5.1.1)

117253 adavis: Merged 5.0.2-CLOUD (Cloud ) to 5.0.2-CLOUD42 (Cloud )
      114523 adavis: Merged BCRYPT to 5.0.2-CLOUD
         114045 gcornwell: MNT-14892: Enabled the UpgradePasswordHashJob (it won't run until 2099 though due to the default cron experssion) and tweaked log statements.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.1.N/root@117346 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2015-11-11 18:01:59 +00:00
parent c340c59c64
commit f9ff45eda1
2 changed files with 9 additions and 12 deletions

View File

@@ -283,10 +283,9 @@
</bean>
<!-- Definition for the upgrade password hash job -->
<!--
<bean id="upgradePasswordHashJobDetail" class="org.springframework.scheduling.quartz.JobDetailBean">
<property name="jobClass"
value="org.alfresco.repo.security.authenticationUpgradePasswordHashWorker$UpgradePasswordHashJob" />
value="org.alfresco.repo.security.authentication.UpgradePasswordHashWorker$UpgradePasswordHashJob" />
<property name="jobDataAsMap">
<map>
<entry key="upgradePasswordHashWorker" value-ref="upgradePasswordHashWorker" />
@@ -299,6 +298,5 @@
<property name="cronExpression" value="${system.upgradePasswordHash.jobCronExpression}" />
<property name="startDelayMinutes" value="${system.cronJob.startDelayMinutes}" />
</bean>
-->
</beans>

View File

@@ -235,9 +235,9 @@ public class UpgradePasswordHashWorker implements ApplicationContextAware, Initi
doWork(progress);
// Done
if (logger.isDebugEnabled())
if (logger.isInfoEnabled())
{
logger.debug("Upgrade password hash job " + progress);
logger.info("Finished upgrade password hash job: " + progress);
}
}
catch (LockAcquisitionException e)
@@ -359,6 +359,11 @@ public class UpgradePasswordHashWorker implements ApplicationContextAware, Initi
this.progress = progress;
this.maxNodeId = patchDAO.getMaxAdmNodeID();
this.userTypeId = qnameDAO.getQName(ContentModel.TYPE_USER);
if (logger.isDebugEnabled())
{
logger.debug("Max NodeID: " + this.maxNodeId);
}
}
@Override
@@ -367,12 +372,6 @@ public class UpgradePasswordHashWorker implements ApplicationContextAware, Initi
// execute a query to get total number of user nodes in the system.
long totalUserCount = patchDAO.getCountNodesWithTypId(ContentModel.TYPE_USER);
if (logger.isDebugEnabled())
{
logger.debug("Max NodeID: " + this.maxNodeId);
logger.debug("Total number of users: " + totalUserCount);
}
return (int)totalUserCount;
}