mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-10-08 14:51:49 +00:00
Merged 5.0.N (5.0.3) to HEAD (5.1)
109927: Merged 5.0.2 (5.0.2) to 5.0.N (5.0.3) 109904: MNT-14463: Deadlock during startup - DictionaryDAO refinements for destroy, init and reload; includes javadoc on API - Proper sequence for custom repo-based models: - Destroy dictionary and force synchronous reload of basic models (reload) - Register listeners - Force async reload of dictionary (init), which does the repo-based loading of models git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@109937 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -624,13 +624,20 @@ implements TenantDeployer, DictionaryListener, /*TenantDictionaryListener, */Mes
|
||||
@Override
|
||||
protected void onBootstrap(ApplicationEvent event)
|
||||
{
|
||||
// Reset the dictionary (destroy and reload)
|
||||
// Reset the dictionary (destroy and reload) in order to ensure that we have a basic version of
|
||||
// the dictionary (static models) loaded at least
|
||||
dictionaryDAO.reset();
|
||||
|
||||
// Register listeners
|
||||
// Register listeners, which will be called when the dictionary is next reloaded
|
||||
register();
|
||||
|
||||
// Trigger a reload.
|
||||
// The callbacks, which will occur asynchronously, will load the custom models from the repository.
|
||||
dictionaryDAO.init();
|
||||
|
||||
// The listeners can now know about this
|
||||
// However, the listeners will be needing to access the dictionary themselves, hence the earlier 'reset'
|
||||
// to ensure that there is no deadlock waiting for a new dictionary
|
||||
((ApplicationContext) event.getSource()).publishEvent(new DictionaryRepositoryBootstrappedEvent(this));
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user