In the SCA Policy framework spec there is a section that talks about
bindingType as it appears in the definitions.xml file(s). It says...

702 The bindingType element is used to declare a class of binding available
in a SCA Domain. It declares
703 the QName of the binding type, and the set of intents that are natively
provided using the optional
704 @alwaysProvides attribute.

I hadn't noticed this before but the implication of these words appears to
be that a particular binding is not available for use in a domain unless
there is a

709 <bindingType type="NCName"
710 alwaysProvides="listOfQNames"?
711 mayProvide="listOfQNames"?/>

element in the aggregate definitions.xml file.

I guess this also applies to implementationType (which is defined in the
assembly spec) and interfaceType and databindingType (which aren't defned in
the assembly spec so I just made them up here)

Currently Tuscany uses the Java services approach to detect and load
extensions. If an extension is loaded it is available for use. We don't
check that bindingType, implementationType, etc is declared before making an
extension available.

As it happens some for our extensions include a defintions.xml file, for
example,
http://svn.apache.org/repos/asf/incubator/tuscany/java/sca/modules/binding-ws-axis2/src/main/resources/org/apache/tuscany/sca/binding/ws/axis2/definitions.xml.
And in this particular example a bindingType is defined. However this is not
true of all of our extensions.

Should we enforce the presence of a definitions.xml file in our extensions
and enforce that it contains an appropriate ?Type elemenent? On the face of
it there seems little benefit to doing this given our Tuscany specific
scheme for loading extensions. However it would tip our hat to the spec,
assuming we agree this is what the spec means, and give us a place to put
other extension configuration information it the need were to arise.

Thoughts?

Regards

Simon

Reply via email to