Update Site Discovery

From Eclipsepedia

Jump to: navigation, search

In preparation for EclipseCon...and just because it's kind of fun...I created a couple of plugins to implement updatesite discovery using the ECF discovery API.

What is updatesite discovery, you say? Well, first I built a simple updatesite http server that uses the OSGI http service/jetty to expose access to a local update site. This server also registers an updatesite service type via the ECF discovery API...so that clients can discover and then access the update site (i.e. to install any features exposed by the site).

This server is defined in a single plugin in this project set file [1]. There's a launch configuration in there to start this server. I'll be adding a equinox application to this so it can be started from command line.

The other part of this is the client. This code is located in this project set file [2]. This client simply extends the ECF discovery view using the new serviceAccessHandler extension point. So, when the server from above is run, a client on the same LAN will see:


Discovery1.PNG


And then if they open up the update site service they will see something like this:


Discovery2.PNG


Then if they open up the context menu on the 'slewis update site' they will see this (this is the ui contribution contributed by the client plugin):


Discovery3.PNG


It's left as an exercise for the reader to predict what choosing either of these menu items does.

[1] anonymous: http://www.eclipse.org/ecf/projectsetfiles/ecf.examples.updatesite.server.anonymous.psf

committer: http://www.eclipse.org/ecf/projectsetfiles/ecf.examples.updatesite.server.committer.psf

[2] anonymous: http://www.eclipse.org/ecf/projectsetfiles/ecf.examples.updatesite.client.anonymous.psf

committer: http://www.eclipse.org/ecf/projectsetfiles/ecf.examples.updatesite.client.committer.psf