Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 100635 Details for
Bug 232366
Update site URLs in feature.xml are ignored
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Fix
patch.txt (text/plain), 2.34 KB, created by
John Arthorne
on 2008-05-16 09:24:54 EDT
(
hide
)
Description:
Fix
Filename:
MIME Type:
Creator:
John Arthorne
Created:
2008-05-16 09:24:54 EDT
Size:
2.34 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.equinox.p2.updatesite >Index: src/org/eclipse/equinox/internal/p2/updatesite/metadata/UpdateSiteMetadataRepository.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.equinox/p2/bundles/org.eclipse.equinox.p2.updatesite/src/org/eclipse/equinox/internal/p2/updatesite/metadata/UpdateSiteMetadataRepository.java,v >retrieving revision 1.35 >diff -u -r1.35 UpdateSiteMetadataRepository.java >--- src/org/eclipse/equinox/internal/p2/updatesite/metadata/UpdateSiteMetadataRepository.java 15 May 2008 18:12:38 -0000 1.35 >+++ src/org/eclipse/equinox/internal/p2/updatesite/metadata/UpdateSiteMetadataRepository.java 16 May 2008 13:24:30 -0000 >@@ -160,6 +160,7 @@ > } > allSiteIUs.add(featureIU); > allSiteIUs.add(groupIU); >+ publishSites(feature); > } > > for (int i = 0; i < siteCategories.length; i++) { >@@ -241,4 +242,33 @@ > //nothing to do > } > >+ /** >+ * Broadcast events for any discovery sites associated with the feature >+ * so the repository managers add them to their list of known repositories. >+ */ >+ private void publishSites(Feature feature) { >+ IProvisioningEventBus bus = (IProvisioningEventBus) ServiceHelper.getService(Activator.getBundleContext(), IProvisioningEventBus.SERVICE_NAME); >+ if (bus == null) >+ return; >+ URLEntry[] discoverySites = feature.getDiscoverySites(); >+ for (int i = 0; i < discoverySites.length; i++) >+ publishSite(feature, bus, discoverySites[i].getURL(), false); >+ String updateSite = feature.getUpdateSiteURL(); >+ if (updateSite != null) >+ publishSite(feature, bus, updateSite, true); >+ } >+ >+ /** >+ * Broadcast a discovery event for the given repository location. >+ */ >+ private void publishSite(Feature feature, IProvisioningEventBus bus, String locationString, boolean isEnabled) { >+ try { >+ URL siteLocation = new URL(locationString); >+ bus.publishEvent(new RepositoryEvent(siteLocation, IRepository.TYPE_METADATA, RepositoryEvent.DISCOVERED, isEnabled)); >+ bus.publishEvent(new RepositoryEvent(siteLocation, IRepository.TYPE_ARTIFACT, RepositoryEvent.DISCOVERED, isEnabled)); >+ } catch (MalformedURLException e) { >+ LogHelper.log(new Status(IStatus.WARNING, Activator.ID, "Feature references invalid site: " + feature.getId(), e)); //$NON-NLS-1$ >+ } >+ } >+ > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 232366
: 100635 |
104351
|
104377