You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@tuscany.apache.org by SALIM Fahim <sa...@gmail.com> on 2008/12/06 17:01:26 UTC
@Callback annotation
Hi all
I have another question concerning annotation.
If I want to use @Callback for two components
1/ does it mean that component1 invoque some method of component2 and
then component1 method is invoked from component2 ?
A kind of request-response interaction behaviour
2/ or does it mean that component2 can invoke some method of component1
wathever component1 is doing ?
A kind of notification message
Is the interaction necessary done in an asynchronous manner ?
Thanks
Fahim
Re: @Callback annotation
Posted by fahim salim <sa...@gmail.com>.
Hi Simon
Thanks for your response
Regards
Fahim
2008/12/8 Simon Laws <si...@googlemail.com>
> Hi Fahim
>
> Comments in line...
>
> Regards
>
> Simon
>
> On Sat, Dec 6, 2008 at 4:01 PM, SALIM Fahim <sa...@gmail.com> wrote:
>
>> Hi all
>>
>> I have another question concerning annotation.
>> If I want to use @Callback for two components
>>
>> 1/ does it mean that component1 invoque some method of component2 and then
>> component1 method is invoked from component2 ?
>> A kind of request-response interaction behaviour
>
>
> Yes, that's the idea. Imagine that you have components A and B. Initially A
> calls B and then continues processing. At some time in the future B calls
> back to A.
>
> A B
> -- --
> |------------>|
> | |
> | |<--------|
> | |
>
>
>>
>> 2/ or does it mean that component2 can invoke some method of component1
>> wathever component1 is doing ?
>> A kind of notification message
>
>
> No, the idea is to provide a mechanism where B can operate asynchronously
> of A and return results to A at some point in the future without A having to
> block waiting for the results.
>
>
>>
>> Is the interaction necessary done in an asynchronous manner ?
>>
>>
>> Thanks
>> Fahim
>>
>>
>
Re: @Callback annotation
Posted by Simon Laws <si...@googlemail.com>.
Hi Fahim
Comments in line...
Regards
Simon
On Sat, Dec 6, 2008 at 4:01 PM, SALIM Fahim <sa...@gmail.com> wrote:
> Hi all
>
> I have another question concerning annotation.
> If I want to use @Callback for two components
>
> 1/ does it mean that component1 invoque some method of component2 and then
> component1 method is invoked from component2 ?
> A kind of request-response interaction behaviour
Yes, that's the idea. Imagine that you have components A and B. Initially A
calls B and then continues processing. At some time in the future B calls
back to A.
A B
-- --
|------------>|
| |
| |<--------|
| |
>
> 2/ or does it mean that component2 can invoke some method of component1
> wathever component1 is doing ?
> A kind of notification message
No, the idea is to provide a mechanism where B can operate asynchronously
of A and return results to A at some point in the future without A having to
block waiting for the results.
>
> Is the interaction necessary done in an asynchronous manner ?
>
>
> Thanks
> Fahim
>
>