Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » P2 » How to add <references> to metadata repository
How to add <references> to metadata repository [message #568153] Wed, 04 August 2010 12:06 Go to next message
Martin Skorsky is currently offline Martin SkorskyFriend
Messages: 112
Registered: July 2009
Senior Member
How can I add <references> to a metadata repository?
When I add a section
<references size='2'>
<repository uri='http://www.example.com/eclipse/updates' url='http://www.example.com/eclipse/updates' type='0' options='0'/>
<repository uri='http://www.example.com/eclipse/updates' url='http://www.example.com/eclipse/updates' type='1' options='0'/>
</references>
to content.xml
this update site is listed in the Available Software Sites.

Can some task during PDE build do this?
Are the details of <references> documented somewhere?
Is there some other tooling in p2 to add this to content.xml?
Re: How to add <references> to metadata repository [message #571172 is a reply to message #568153] Thu, 12 August 2010 15:55 Go to previous message
Andrew Niefer is currently offline Andrew NieferFriend
Messages: 990
Registered: July 2009
Senior Member
Site.xml files can be used to categorize your repository. You specify it
using "p2.category.site"
http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse. pde.doc.user/tasks/pde_p2_productbuilds.htm

I've never tried this myself, but it appears that old style update sites had
an attribute "associateSitesURL".
There is some documentation here:
http://help.eclipse.org/ganymede/index.jsp?topic=/org.eclips e.platform.doc.isv/reference/misc/update_sitemap.html
This should be a relative url which points to an xml file which lists the
assoicated sites.

Looking at the code p2 publishing code
(SiteXMLAction#getFeatureToCategoryMappings), it appears that if the
site.xml contains the associateSitesURL, then these URLs will be read and
set on the repository as references.

Using the "p2.category.site" property to categorize your build will probably
add the references to the internal build repo and not the final result repo
because I don't believe these references are mirrored between repos.

You probably have make an extra call to add these to the final repo, you can
do this with the <eclipse.publish.featuresAndBundles/> ant task
http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse. pde.doc.user/tasks/pde_p2_buildtasks.htm
<eclipse.publish.featuresAndBundles repository="file:/build/repository"
site="file:/build/site.xml" >

It may also be possible to use the UpdateSite Publisher application
http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse. platform.doc.isv/guide/p2_publisher.html


Martin Skorsky wrote:

> How can I add <references> to a metadata repository?
> When I add a section
> <references size='2'>
> <repository uri='http://www.example.com/eclipse/updates'
> url='http://www.example.com/eclipse/updates' type='0' options='0'/>
> <repository uri='http://www.example.com/eclipse/updates'
> url='http://www.example.com/eclipse/updates' type='1' options='0'/>
> </references>
> to content.xml
> this update site is listed in the Available Software Sites.
>
> Can some task during PDE build do this?
> Are the details of <references> documented somewhere?
> Is there some other tooling in p2 to add this to content.xml?
Previous Topic:Referencing a fragment instance in a touchpoint action
Next Topic:How to add <references> to metadata repository
Goto Forum:
  


Current Time: Thu Apr 25 07:00:13 GMT 2024

Powered by FUDForum. Page generated in 0.03219 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top