private void synchronizeShadowsAtStartup() {
final Collection<ShadowRepository> shadows = repositoryRegistry.getRepositoriesWithFacet(ShadowRepository.class);
for (ShadowRepository shadow : shadows) {
if (shadow.isSynchronizeAtStartup()) {
final SynchronizeShadowsTask task = nexusScheduler.createTaskInstance(SynchronizeShadowsTask.class);
task.setShadowRepositoryId(shadow.getId());
nexusScheduler.submit("Shadow Sync (" + shadow.getId() + ")", task);
}
}
}