Venkat,

Responses inline....

Yours,  Mike.

Venkata Krishnan wrote:
Hi,

I am trying to bring the SPI model and the Loaders in sync with the current
level of the specs as available on OSOA site.  I am currently looking at
'references' - as and how they are defined in ComponentType,
ComponentDefinition and Composite and have the following questions:  -

With respect to references defined in ComponentDefitions and the 'target'
attribute therein
- the specs says that whatever is mentioned in the target overrides that
which is mentioned in the implementation.  Now, my understanding is that a
target is used to wire a reference to another Component's service.  Given
this, I thought defining a target makes sense only within a composite.  So
what does it mean by an implementation specifying a target for a reference?

Part of the recent work on the Assembly spec allows for "fully configured implementations". In effect this means that an implementation can contain full SCA metadata and that the implementation can be deployed without the need for any further configuration metadata. An example might be a Java class bristling with annotations, which could include annotations for references that would include target information. The targets would be meaningful in terms of an SCA domain into which the implementations are deployed eg "fooComponent/barService" as a target spec, where fooComponent is known to be another component deployed to the Domain.

Under these circumstances, if there is a need to reuse such a fully configured implementation, then the composite (re)using the implementation must have the means to override the metadata in the implementation.


- next, the 'target' attribute for a reference in a component definition is
'optional'. Assuming there are no targets defined in the implementation and
no targets are defined in the component definition that uses this
implementation (as this is only optional), then what happens to these
references.  Is this something that should not be permitted unless
autowire=true for the reference defn.

Remember that a wire can EITHER be specified using the target attribute of a reference OR using a standalone wire element. Forgetting about autowire and promotion and wiredByImpl, it IS a requirement that a (1..1 or 1..n) reference is not left dangling. It is an error if there is no wire under these circumstances. Clearly for (0..1 and 0..n) multiplicity, a reference can validly be left unwired.

The use of standalone wire elements is of particular use at the Domain level, where wiring can be deployed separately from the components, allowing separation of responsibilities.


Could somebody familiar with the specs kindly help me with understand?
Thanks.

- Venkat


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to