Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 324215 - [remoteserviceadmin][remoteservices] implement remote services admin spec
Summary: [remoteserviceadmin][remoteservices] implement remote services admin spec
Status: RESOLVED FIXED
Alias: None
Product: ECF
Classification: RT
Component: ecf.remoteservices (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: 3.5.0   Edit
Assignee: Scott Lewis CLA
QA Contact:
URL:
Whiteboard:
Keywords: helpwanted, plan
Depends on: 335419 335483
Blocks: 302113 337242
  Show dependency tree
 
Reported: 2010-09-01 11:31 EDT by Scott Lewis CLA
Modified: 2011-02-15 14:35 EST (History)
7 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Scott Lewis CLA 2010-09-01 11:31:16 EDT
In OSGi 4.2 enterprise spec chapter 122 is the remote services admin specification.  As of version 3.3, ECF fully implements the remote services spec (chapter 13 in compendium), but ECF does not yet implement the remote services admin spec.  

This enhancement would be to implement the remote services admin spec upon the ECF discovery API, ECF remote services API, and the ECF OSGi remote services implementation.
Comment 1 Scott Lewis CLA 2010-09-23 17:18:09 EDT
For everyone's info:  work on this has started...and it should be fairly quick to complete (est 1 month).  Since ECF's existing architecture (i.e. as described here:  http://wiki.eclipse.org/OSGi_4.2_Remote_Services_and_ECF) is already modular, with a clean separation between APIs for both discovery and distribution, it will be very simple to add an ECF-based impl of Remote Services Admin specification.
Comment 2 Markus Kuppe CLA 2010-09-24 03:12:16 EDT
Do you expect to make any changes that will involve the consumer/provider side of a service? From my understanding of the remote services admin spec, this should not be necessary, but asking anyway.
Comment 3 Markus Kuppe CLA 2010-09-24 05:59:07 EDT
Marking bug #326132 as a dependent. Feel free to remove if not applicable.
Comment 4 Scott Lewis CLA 2010-09-24 10:15:38 EDT
(In reply to comment #2)
> Do you expect to make any changes that will involve the consumer/provider side
> of a service? From my understanding of the remote services admin spec, this
> should not be necessary, but asking anyway.

I think the answer to your question is probably 'yes'.  The rsa does have the concept of both export registrations/references (host) and import registrations/references (consumer) available via the remote service admin service.  So to add these it may involve some changes (mostly additions, I think), to the consumer impl of distribution.
Comment 5 Scott Lewis CLA 2010-09-24 10:42:15 EDT
Removing blocking dependency on bug 326132.  I don't immediately see how they are related.
Comment 6 Scott Lewis CLA 2010-09-25 16:00:11 EDT
I've retrieved the OSGI remote services admin package (org.osgi.service.remoteserviceadmin), and create a project out of it...with name org.eclipse.osgi.services.remoteserviceadmin.  The name of the project/bundle (org.eclipse.osgi.services.remoteserviceadmin) was patterned after the Equinox naming of the bundle responsible for OSGi service classes (org.eclipse.osgi.services).  It only contains classes that are part of the org.osgi.service.remoteserviceadmin package.  The piggyback CQ for this third party library usage by ECF is http://dev.eclipse.org/ipzilla/show_bug.cgi?id=4470.

This project has now been released to HEAD...in a new ECF module in CVS:  /cvsroot/rt/org.eclipse.ecf/osgi/bundles.
Comment 7 Scott Lewis CLA 2010-11-02 13:52:36 EDT
(In reply to comment #6)

Here is a brief update about the progress on RSA (Remote Services Admin) development.  

ECF has moved to git, and the new plugins for RSA have moved to the following locations in the ECF git repository

top:  http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/

OSGi RSA classes (part of OSGi EE distribution):
bundle:  org.eclipse.osgi.services.remoteserviceadmin
Location:  http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/tree/osgi/bundles/org.eclipse.osgi.services.remoteserviceadmin
Status:  Supplied by OSGi consortium.  Not under active development.

ECF's RSA implementation (under construction)
bundle:  org.eclipse.ecf.osgi.services.remoteserviceadmin
Location:  http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/tree/incubation/bundles/org.eclipse.ecf.osgi.services.remoteserviceadmin
Status:  Under active development.  The discovery/EndpointDescription described in RSA spec is mostly complete, and test code has been started (see test bundle below).  The parser for parsing EndpointDescriptions from static xml files (as described in spec) has been implemented and tested (11/1/2010).  Next steps:  integrate parser with BundleTracker mechanism described in spec to read EndpointDescriptions from bundles.

Test code
bundle: org.eclipse.ecf.tests.osgi.services.remoteserviceadmin
Location:  http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/tree/incubation/bundles/org.eclipse.ecf.tests.osgi.services.remoteserviceadmin
Status:  Under active development, and used for testing ECF's RSA implementation.
Comment 8 Scott Lewis CLA 2010-11-02 20:40:19 EDT
Setting target milestone to 3.5
Comment 9 Scott Lewis CLA 2010-11-29 14:18:06 EST
Status update:  Over the past few weeks, I've made significant progress on the ECF impl of OSGi remote services admin.  See comment 7 for access to the source.

Soon this impl will be complete and under test.  If others can help with reviewing the implementation, asking questions, reviewing spec compliance, etc that would be very helpful.  Please indicate on this bug how you would be able to help.
Comment 10 Pierre-Henry Perret CLA 2010-11-30 06:41:15 EST
Would be interested in testing JGroups transport.
Comment 11 Scott Lewis CLA 2010-12-14 10:53:57 EST
Status update.  A functional instance of ECF's remote services admin is now in place.  See comment 7 for repository location.

The RSA impl is not yet complete, however.  Specifically, the unregistering of remote services and handling of connection failure/cleanup has yet to be completed.  Also there is much testing to be done...and the copying/moving of our existing remote services test code to use RSA rather than the old implementation.  There is also work to do to finish spec compliance (e.g. notification via RemoteServiceEvents), and some other ECF-specific things that should probably be added (e.g. the IProxy/HostDistributionListener).  I anticipate completing most of these things before Jan 2011...during the holidays.

Please bring up things either on ecf-dev mailing list, or on this bug, or on new bug (with [remoteserviceadmin] in header please).
Comment 12 Wim Jongman CLA 2011-01-11 17:54:17 EST
Chapter 122 describing the spec is in this book:

http://www.osgi.org/download/r4v42/r4.enterprise.pdf
Comment 13 Scott Lewis CLA 2011-01-24 13:51:06 EST
Status update:  The initial implementation of the RSA spec is ready and working.

I've moved the remote service admin bundle (org.eclipse.ecf.osgi.services.remoteserviceadmin) from the incubator area of the git repo to a permanent location.  That location is here:

http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/tree/osgi/bundles/org.eclipse.ecf.osgi.services.remoteserviceadmin

In addition to ECF remote service API and ECF discovery API, this implementation depends (of course) on the OSGI 4.2 RSA spec classes, and these classes are located here:

http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/tree/osgi/bundles/org.eclipse.osgi.services.remoteserviceadmin

In summary, the two RSA implementation bundles are in this module

<ecf git repo>/osgi/bundles

The RSA implementation (org.eclipse.ecf.osgi.services.remoteserviceadmin) has dependencies on 

1) OSGi 4.2 RSA spec-defined classes.  In project: org.eclipse.osgi.services.remoteserviceadmin

2) ECF discovery API.  In project:  org.eclipse.ecf.discovery

3) ECF remote service API.  In project:  org.eclipse.ecf.remoteservice

4) ECF identity/core.  This comes with Eclipse as target platform, but also available via project in <ecf git repo>/framework/bundles

5) Equinox common, equinox eventmgr, equinox concurrent APIs.

Tests

I am working now to integrate/change the existing OSGi test code to use the RSA.  This has two aspects:

1) Introducing new RSA-specifc test code.  I will be doing this by adding test bundles to the test area as quickly as I can (I have several new tests specific to RSA and have been using them to debug/test the RSA impl, but have not yet made them public).  I will do so.
2) Changing over the existing ECF remote service implementation (i.e. in org.eclipse.ecf.osgi.services.discovery and o.e.e.osgi.services.distribution) to use/depend upon RSA.  Once this is done, we should be able to use the existing OSGi test code (and example code) to test RSA.

If there are any questions and/or comments or suggestions, please just raise them as comments on this bug.
Comment 14 Markus Kuppe CLA 2011-01-28 03:45:13 EST
Hi,

with commit [0], ecf.rmap has been changed to locate "org.eclipse.osgi.*" bundles in the "org.eclipse.ecf" search path. This is going to fail if e.g. 
org.eclipse.osgi.services_*.jar or org.eclipse.osgi.util_*.jar is searched for. Those bundles are not part of ECF's search path.

Can this regexp be done less generic/broad, e.g. "^org\.eclipse\.osgi\.services\.(\..+)?"

Markus

[0] http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/commit/?id=409d421bf9678ad4b541bb816c532897dc522a09
Comment 15 Martin Petzold CLA 2011-02-13 08:30:08 EST
Well implemented AbstractContainerSelector, this will solve all of my problems, I hope =). Shall I (try to) write the Javadocs in there?

Martin
Comment 16 Scott Lewis CLA 2011-02-13 11:59:46 EST
(In reply to comment #15)
> Well implemented AbstractContainerSelector, this will solve all of my problems,
> I hope =). Shall I (try to) write the Javadocs in there?
> 
> Martin

I/Scott am working on javadocs for RSA classes right now/this week, but I haven't gotten to AbstractContainerSelector yet...so please go ahead with javadocs on this class (and super/subclasses)...if you have bandwidth to do so.  Please coordinate directly with me (so we don't overlap/waste effort).
Comment 17 Scott Lewis CLA 2011-02-15 14:04:29 EST
The ECF implementation of the OSGi 4.2 Remote Services Admin spec (chap 122 in enterprise specification) is now present in ECF git repo, as well as the results of the ECF builder...i.e. the the ECF remote service target components and the ECF SDK repos.

The main bundle/project for this implementation is here:

http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/tree/osgi/bundles/org.eclipse.ecf.osgi.services.remoteserviceadmin

This bundle depends upon the OSGi 4.2 rsa classes, which are provided via the OSGi consortium and are included in ECF via this bundle/project:

http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/tree/osgi/bundles/org.eclipse.osgi.services.remoteserviceadmin

The remote service tests (i.e. those in org.eclipse.ecf.tests.osgi.distribution.*) pass, and now use the RSA implementation underneath rather than the implementation based upon RFC 119 designs/code.  More tests should/need to be created, to test the various parts/customizable services for the ECF implementation.

Except for the Zookeeper discovery provider bug 335419, the hello example applications now run using the RSA implementation...using either the generic or r-osgi remote service providers.  Other providers (e.g. xml-rpc) should probably be added and tested...via other enhancements.

I'm resolving this plan bug as fixed in preparation for inclusion in ECF 3.5 release (scheduled for approximately March 14.  

I/Scott am working on the javadocs for the ECF remote service admin interfaces and classes, and will create as much other/wiki documentation as I can...along with coordinating documentation contributions from the community (e.g. comment 15).

RSA bugs...and/or RSA enhancements should be created with [remoteserviceadmin] in the subject line.