Examples of DistributionSourceSynchronizer


Examples of org.rhq.enterprise.server.plugin.pc.content.sync.DistributionSourceSynchronizer

            log.debug("synchronizeRepo :: synchronizeDistributionMetadata");
            for (ContentSource source : repo.getContentSources()) {
                try {
                    ContentProvider provider = getIsolatedContentProvider(source.getId());
                    if (provider instanceof DistributionSource) {
                        DistributionSourceSynchronizer distroSourceSyncer = new DistributionSourceSynchronizer(
                            repo, source, provider);
                        tracker = updateSyncStatus(tracker, ContentSyncStatus.DISTROMETADATA);
                        tracker = distroSourceSyncer.synchronizeDistributionMetadata(tracker);
                        tracker = updatePercentComplete(tracker, repoManager);
                    }
                } catch (Exception e) {
                    processSyncException(e, tracker, repo, source, repoManager);
                }
                // Check for cancellation after each content source.
                ThreadUtil.checkInterrupted();
            }

            // Sync distro bits.
            log.debug("synchronizeRepo :: synchronizeDistributionBits");
            for (ContentSource source : repo.getContentSources()) {
                try {
                    ContentProvider provider = getIsolatedContentProvider(source.getId());
                    if (provider instanceof DistributionSource) {
                        DistributionSourceSynchronizer distroSourceSyncer = new DistributionSourceSynchronizer(
                            repo, source, provider);
                        tracker = updateSyncStatus(tracker, ContentSyncStatus.DISTROBITS);
                        tracker = distroSourceSyncer.synchronizeDistributionBits(tracker);
                        tracker = updatePercentComplete(tracker, repoManager);
                    }
                    ThreadUtil.checkInterrupted();
                } catch (Exception e) {
                    processSyncException(e, tracker, repo, source, repoManager);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.