Hi,

Do you already have a service running with binding.atom at http://localhost:8084/customer?

Your client is trying to connect to this address using the ATOM over HTTP.

Thanks,
Raymond
--------------------------------------------------
From: "Dan Becker" <[EMAIL PROTECTED]>
Sent: Thursday, July 10, 2008 1:20 PM
To: <[email protected]>
Subject: Question on Atom bindings (and SCA references in general)

This a question on the Atom binding implementation in java/sca/modules/binding-atom-abdera, but the answer might also be interesting to general SCA users as well.

There is an SCA Consumer.composite that has this SCA component and binding mentioned in it:
    <component name="CustomerClient">
<implementation.java class="org.apache.tuscany.sca.binding.atom.CustomerClientImpl"/>
        <reference name="resourceCollection">
        <tuscany:binding.atom uri="http://localhost:8084/customer"/>
        </reference>
    </component>

If I look into the CustomerClientImpl class, I see a reference to a number of resources exposed as a Collection (this is an atom.collection, not to be confused with a java.util.Collection) as such:
   public class CustomerClientImpl implements CustomerClient {
       @Reference
       public Collection resourceCollection;
       ...
   }

Can someone explain to be the accessibility of this implementation field? Even if I expose this in the CustomerClient interface (e.g. public Collection getCollection() ), I find that clients cannot access this collection and use the Collection methods (get, put, post, delete, ...). I see this type of exception: org.osoa.sca.ServiceRuntimeException: java.net.ConnectException: Connection refused: connect at org.apache.tuscany.sca.binding.atom.provider.AtomBindingInvoker$PostInvoker.invoke(AtomBindingInvoker.java:207) at org.apache.tuscany.sca.core.databinding.wire.PassByValueInterceptor.invoke(PassByValueInterceptor.java:112)

Is there a limit to the visibility/usability fields of a binding? Or is there another way to access this field from a client? Hints are appreciated.

--
Thanks, Dan Becker

Reply via email to