public boolean populate ( ContextRefreshedEvent event ) { boolean databasePopulated = isDatabasePopulated ( ) ; if ( ! databasePopulated ) { LOG . trace ( "Populating database with I18N strings ..." ) ; i18nPopulator . populateLanguages ( ) ; LOG . trace ( "Populated database with I18N strings" ) ; } LOG . trace ( "Populating plugin entities ..." ) ; pluginPopulator . populate ( event . getApplicationContext ( ) ) ; LOG . trace ( "Populated plugin entities" ) ; LOG . trace ( "Populating settings entities ..." ) ; settingsPopulator . initialize ( event ) ; LOG . trace ( "Populated settings entities" ) ; LOG . trace ( "Populating default genome browser attributes ..." ) ; genomeBrowserAttributesPopulator . populate ( ) ; LOG . trace ( "Populated default genome browser attributes" ) ; LOG . trace ( "Populating database with I18N strings ..." ) ; i18nPopulator . populateL10nStrings ( ) ; LOG . trace ( "Populated database with I18N strings" ) ; LOG . trace ( "Populating script type entities ..." ) ; scriptTypePopulator . populate ( ) ; LOG . trace ( "Populated script type entities" ) ; if ( ! databasePopulated ) { LOG . trace ( "Populating database with users, groups and authorities ..." ) ; usersGroupsAuthoritiesPopulator . populate ( ) ; LOG . trace ( "Populated database with users, groups and authorities" ) ; // populate repositories with application-specific entities LOG . trace ( "Populating database with application entities ..." ) ; systemEntityPopulator . populate ( event ) ; LOG . trace ( "Populated database with application entities" ) ; } LOG . trace ( "Populating dynamic decorator entities ..." ) ; dynamicDecoratorPopulator . populate ( ) ; LOG . trace ( "Populated dynamic decorator entities" ) ; return databasePopulated ; }
Returns whether the database was populated previously .