Hi Jun Guo

Comments in line...

Regards

Simon

On Mon, Dec 1, 2008 at 7:11 AM, kujunguo kujunguo <[EMAIL PROTECTED]>wrote:

> I defined a composite like this:
>
> <component name="MyServiceClientComponent">
>    <implementation.java class="com.ibm.was.sca.callback.MyClientImpl"/>
>    <reference name="myService" target="MyServiceImplComponent/MyService">
>
>            <callback>
>                <binding.sca/>
>                <binding.jms/>
>                <binding.ws uri="http://localhost:8087/MyService"/>
>                <binding.ws uri="http://localhost:8088/MyService"/>
>            </callback>
>
>        </reference>
>
>    </component>
>
>    <component name="MyServiceImplComponent">
>        <implementation.java
> class="com.ibm.was.sca.callback.MyServiceImpl"/>
>
>        <service name="MyService">
>            <!--<interface.java
> interface="com.ibm.was.sca.callback.MyService"/>-->
>            <callback>
>                <binding.sca/>
>                <binding.jms/>
>                <binding.ws uri="http://localhost:8087/MyService"/>
>            </callback>
>        </service>
>
>    </component>
>
> When I ran the test case for it, no error, but I have some question for it:
> 1) Do we need to declare both callback bindings in <reference> and
> <service> elements?


The ability to define multiple bindings allows the runtime to pick the most
appropriate bindings when sending the callback message from the service back
to the client.


>
> 2) How to verify all bindings take effect in my running?


I don't think that all of the bindings will take effect but I'd have to go
and check the code to see which one will be chosen. I suspect it will just
pick the first one that matches between service and client, in this case
binding.sca

Reply via email to