Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 342356

Summary: [TCK] RSA override properties handling incomplete
Product: [RT] ECF Reporter: Markus Kuppe <bugs.eclipse.org>
Component: ecf.remoteservicesAssignee: Markus Kuppe <bugs.eclipse.org>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: slewis
Version: 3.5.0   
Target Milestone: 3.5.1   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
mylyn/context/zip none

Description Markus Kuppe CLA 2011-04-09 11:43:02 EDT
My reading/understanding of o.e.e.osgi.services.remoteserviceadmin.RemoteServiceAdmin.exportService(ServiceReference, Map<String, Object>) javadoc is, that the implementation is supposed to override any properties in the service reference with the one provided in the Map (except the explicitly excluded ones).
Right now this is only done for the exported interfaces, intents and exported configs.
However neither o.e.e.osgi.services.remoteserviceadmin.IHostContainerSelector.selectHostContainers(ServiceReference, String[], String[], String[]) nor o.e.e.osgi.services.remoteserviceadmin.IHostContainerSelector.selectHostContainers(ServiceReference, String[], String[], String[]) actually allow overriding properties to be passed in. 

This e.g. results in "ecf.exported.containerfactoryargs" being ignored by the host container selector.
Comment 1 Markus Kuppe CLA 2011-04-10 03:06:27 EDT
Fix released to HEAD
Comment 2 Markus Kuppe CLA 2011-04-10 03:06:30 EDT
Created attachment 192896 [details]
mylyn/context/zip
Comment 3 Scott Lewis CLA 2011-04-11 09:45:43 EDT
Hi Markus.  I realized last week that this was incomplete.  What was the fix that you imposed?  (I don't use mylyn myself).  Is it an API change?...i.e. change to IHostContainerSelector?  If so, I think we should get a waiver and include fix in 3.5.1 (given that RSA is nw to 3.5).
Comment 4 Markus Kuppe CLA 2011-04-11 10:09:05 EDT
This fix works without changes to IHostContainerSelector. But I intend to open a new bug to also change the IHostContainerSelector API to be able to pass overriding properties to the selector.
Comment 5 Scott Lewis CLA 2011-04-11 10:12:51 EDT
(In reply to comment #4)
> This fix works without changes to IHostContainerSelector. 

How does it do that?  (I don't see the update on master yet)

>But I intend to open
> a new bug to also change the IHostContainerSelector API to be able to pass
> overriding properties to the selector.

Yeah, I think this is the thing to change...a Map as another argument to IHostContainerSelector.  Since this is ECF-specific API, and not a huge API change, I suggest we get a waiver and include in 3.5.1.
Comment 6 Markus Kuppe CLA 2011-04-11 10:27:02 EDT
(In reply to comment #5)

> How does it do that?  (I don't see the update on master yet)

http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/commit/?id=0460ae315c12f6857dc1745718ee3a18a04358f7
Comment 7 Scott Lewis CLA 2011-04-11 12:12:07 EDT
(In reply to comment #6)
> (In reply to comment #5)
> 
> > How does it do that?  (I don't see the update on master yet)
> 
> http://git.eclipse.org/c/ecf/org.eclipse.ecf.git/commit/?id=0460ae315c12f6857dc1745718ee3a18a04358f7

I don't understand what this actually does...could you please explain a little?  Thanks.
Comment 8 Markus Kuppe CLA 2011-04-11 12:38:16 EDT
(In reply to comment #7)

> I don't understand what this actually does...could you please explain a little?
>  Thanks.

It simply merges sref's properties and the overriding properties based on how the spec defines it. The resulting map is used to create/select the endpoint.