While bringing up the Implementation.widget, I have found the
following scenario : A component that has couple references wired via
@target attribute, and all the binding information is available in the
target service.
...
<component name="Store">
<tuscany:implementation.widget location="uiservices/store.html"/>
<service name="Widget">
<tuscany:binding.http uri="/store"/>
</service>
<reference name="catalog" target="Catalog"/>
<reference name="shoppingCart" target="ShoppingCart/Cart"/>
<reference name="shoppingTotal" target="ShoppingCart/Total"/>
</component>
<component name="Catalog">
<implementation.java class="services.FruitsCatalogImpl"/>
<property name="currencyCode">USD</property>
<service name="Catalog">
<tuscany:binding.jsonrpc/>
</service>
<reference name="currencyConverter"
target="CurrencyConverter"/>
</component>
...
In the past, I could easily get access to the binding configuration
via the RuntimeComponent (e.g component.getReferences.getBinding()).
With the recent changes around EndPoint and EndPointReference, how am
I supposed to get access to these info during a invocation of my
extension ? I have tried couple variations without success (e.g
component.getEndpointReferences().get(0).getBinding() which always
return null, and
component.getEndpointReferences().get(0).getTargetEndpoint() which is
always unresolved)
Because I know there are several changes being done on this area at
the moment, I want to double check what should be the expected
behavior and the right approach to access the binding configuration
for the reference on the scenario above, before I start making any
changes on the in flux code.
--
Luciano Resende
http://people.apache.org/~lresende
http://lresende.blogspot.com/