[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] service elements in Declaratice Services


Looks like a bug to me. Open a bug here: https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Equinox

Select the Compendium component and start the summary with [ds].

The schema for the XML only permits a single <service> element. DS should reject the XML as invalid thus ignoring the component description.
--

BJ Hargrave
Senior Technical Staff Member, IBM
OSGi Fellow and CTO of the
OSGi Alliance
hargrave@xxxxxxxxxx

office: +1 386 848 1781
mobile: +1 386 848 3788





From: "Toedter, Kai" <kai.toedter@xxxxxxxxxxx>
To: "Equinox development mailing list" <equinox-dev@xxxxxxxxxxx>
Date: 2008/10/28 09:14 AM
Subject: [equinox-dev] service elements in Declaratice Services





Hi All,

I currently prototype a little Equinox app that uses Declarative Services (DS). The DS spec 4.1 says "The service element is optional. ... The service element must have one or more provide elements that define the service interfaces". So, the following XML is syntactically correct and handled well by Equinox DS:

<component name="com.siemens.ct.pm.ui.views.treeView">
   <implementation
       class="com.siemens.ct.pm.ui.views.treeview.TreeView"/>
   <service>
       <provide
           interface="com.siemens.ct.pm.application.service.IViewContribution"/>
       <provide
           interface="com.siemens.ct.pm.model.IPersonListener"/>
   </service>
</component>

However, the following XML is incorrect with regards to the DS spec...

<component name="com.siemens.ct.pm.ui.views.treeView">
   <implementation
       class="com.siemens.ct.pm.ui.views.treeview.TreeView"/>
   <service>
       <provide
           interface="com.siemens.ct.pm.application.service.IViewContribution"/>
   </service>
   <service>
       <provide
           interface="com.siemens.ct.pm.model.IPersonListener"/>
   </service>
</component>

... but Equinox handles it exactly like the above correct XML :)

Now the question is, is this a bug or a feature?
If it is a bug, I can file it...
...but how should Equinox DS react then?

Best regards,

Kai
---


Kai Tödter

Siemens AG
Corporate Technology
Architecture
CT SE 2
Otto-Hahn-Ring 6
81739 Munich, Germany
Phone: +49 89 636-41064
Fax: +49 89 636-45450
mailto: kai.toedter@xxxxxxxxxxx
Internet:
www.siemens.com/corporate-technology

Siemens Aktiengesellschaft: Chairman of the Supervisory Board: Gerhard Cromme; Managing Board: Peter Loescher, Chairman, President and Chief Executive Officer; Heinrich Hiesinger, Joe Kaeser, Rudi Lamprecht, Eduardo Montes, Juergen Radomski, Erich R. Reinhardt, Hermann Requardt, Uriel J. Sharef, Peter Y. Solmssen, Klaus Wucherer; Registered offices: Berlin and Munich; Commercial registries: Berlin Charlottenburg, HRB 12300, Munich, HRB 6684; WEEE-Reg.-No. DE 23691322



_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev