Does there have to be a wire? An example is something like: sca.module:
<module xmlns="http://www.osoa.org/xmlns/sca/0.9" xmlns:v="http://www.osoa.org/xmlns/sca/values/0.9" name="sampleHelloworld"> <externalService name="HelloWorldService"> <interface.wsdl interface=" http://helloworldaxis.samples.tuscany.apache.org#HelloWorldServiceImpl"/> <binding.ws port=" http://helloworldaxis.samples.tuscany.apache.org#helloworld"/> </externalService> </module> Code: TuscanyRuntime tuscany = new TuscanyRuntime("hello", null); tuscany.start(); CurrentModuleContext.getContext().locateService("HelloWorldService"); which gets: Exception in thread "main" org.apache.tuscany.core.context.ServiceNotFoundException: HelloWorldService at org.apache.tuscany.core.context.impl.TuscanyModuleComponentContextImpl.getInstance (TuscanyModuleComponentContextImpl.java:301) at org.apache.tuscany.core.context.impl.TuscanyModuleComponentContextImpl.locateService (TuscanyModuleComponentContextImpl.java:315) at HelloworldClient.main(HelloworldClient.java:18) ...ant On 2/10/06, Jeremy Boynes <[EMAIL PROTECTED]> wrote: > > ant elder wrote: > > If an sca.module file defines an external service and I call > ModuleContext > > locateService with the external service name it throws a > > ServiceNotFoundException. Page 15 of the "SCA Client and Implementation > > model for Java" makes it sound like locateService should find external > > services. If this is a bug I can raise a JIRA, just checking what is > this > > the expected behaviour? > > > > ...ant > > > > It should find the service that the ExternalService is wired to - in the > absense of a wire then the reference would be unconnected and you'd get > an exception. > > So the question is, does the SCDL define a wire? If it does then, yep, > it's a bug. Note the wire can be supplied by the source module, the > target module, or by another module all together. > > -- > Jeremy >
