Why do these intents with the same name have to be the same instance? We
could have four instances and have each of them point to the corresponding
operation.
If I understand correctly, you're trying to reference (instead of
instantiate) the intents by QName to the ones defined in definitions.xml.
Conceptually, I treat these two as different things:
Intent type ...................... <intent name="tuscany:logging> from
definitions.xml (Defining an intent type)
Intent configuration .......... requires="tuscany:logging" from the
composite file (An intent whose type is tuscany:logging)
Thanks,
Raymond
----- Original Message -----
From: "Venkata Krishnan" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Tuesday, December 11, 2007 8:54 AM
Subject: Re: svn commit: r602804 - in /incubator/tuscany/java/sca/modules:
assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/
assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/impl/
assembly/src/main/java/org/apache/tuscany/sca/assem
Hi,
I went ahead and tried to implement this thinking thro some scenarios
along. Here is one that seemed to have a problem with this approach.
Take
the composite...
<composite...
<component name="CalculatorServiceComponent">
<implementation.java class="calculator.CalculatorServiceImpl">
<operation name="add" requires="tuscany:logging"/>
<operation name="subtract" requires="tuscany:logging"/>
</implementation.java>
</component
<component name="AnotherCalculatorServiceComponent">
<implementation.java class="calculator.CalculatorServiceImpl">
<operation name="multiply" requires="tuscany:logging"/>
<operation name="divide" requires="tuscany:logging"/>
</implementation.java>
</component
</composite>
While processing 'CalculatorServiceComponent' the add and subtract
operations will be added to the logging Intent. While processing the
'AnotherCalculatorServiceComponent' the multiply and divide oeprations
will
be added to the logging intent. Since there is one instance of the
logging
intent that is shared by these two components, it ends up that the logging
intent gets to apply for all four methods in both components, which is not
what is intended.
Thoughts ?
Thanks
- Venkat
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]