You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@tuscany.apache.org by Jean-Jacques Dubray <jd...@gmail.com> on 2008/05/15 22:07:59 UTC

Web Service References

Luciano has pointed me towards a BPEL reference sample. It was constructed
by using the HelloWord sample which "inovkes" a GreetingsService. The
Greeting Service is a regular web service implemented as an SCA composite
(similar to the hello-ws sample).

The hello world bpel definition exposes itself a service.

Even though GreetingsService is a plain vanilla Web Service its reference
definition includes an implementation.java element:

    <component name="GreetingsServiceComponent">
        <implementation.java class="greetings.GreetingsServiceImpl" />

        <service name="GreetingsService">
            <interface.wsdl interface="
http://greetings#wsdl.interface(Greetings)" />
        </service>
    </component>

this is also true for the helloworld-ws-reference sample:

    <reference name="HelloWorldService"
promote="HelloWorldServiceComponent/helloWorldService">
        <interface.java interface="helloworld.HelloWorldService" />
        <binding.ws wsdlElement="
http://helloworld#wsdl.port(HelloWorldService/HelloWorldSoapPort)"/>
    </reference>

Why is not a WSDL enough?

The other question is if you use a WS binding, why does the service has to
be part of the same domain as the consumers? Could they belong to two
different SCA domains? As a matter of fact can a composite consume a WSDL
reference that is not part of an SCA domain at all?

thanks,

-- 
Jean-Jacques Dubray
425-445-4467

Re: Web Service References

Posted by Luciano Resende <lu...@gmail.com>.
Quoting the spec :

"A component element has zero or one implementation element as its
child, which points to the implementation used by the component. A
component with no implementation element is not runnable, but
components of this kind may be useful during a "top-down" development
process as a means of defining the characteristics required of the
implementation before the implementation is written."

So, in order to be able to deploy and run, your component MUST define
it's implementation.


On Fri, May 16, 2008 at 5:01 AM, Jean-Jacques Dubray <jd...@gmail.com> wrote:
> Luciano:
>
> thanks, actually in the test/bpel/helloworld-reference composite definition
> you also have a component defined with a binding.ws and there to, there is
> an implementation.java element. Is it required?
>
> <!-- Simple ws-reference -->
>    <!--
>    <component name="HelloWorldService">
>        <implementation.java class="helloworld.HelloWorldServiceImpl"/>
>        <reference name="greetingsService">
>            <binding.ws uri="http://localhost:8085/GreetingsService"/>
>        </reference>
>    </component>
>    -->
>
> Would you consider ws bindings as the preferred way to implement  cross
> domain composites?
>
> JJ-
>
> On Fri, May 16, 2008 at 12:06 AM, Luciano Resende <lu...@gmail.com>
> wrote:
>
>> Hey Jean-Jacques Dubray
>>
>> Let me try to respond your questions :
>>
>> The helloworld.composite defined in the
>> itest/bpel/helloworld-reference defines a GreetingsServiceComponent
>> that is implemented by a simple pojo and has its interface contract
>> defined by a wsdl, in this case greetings.wsdl.  This component does
>> not use the binding.ws, thus is not exposed as web services.
>>
>> The helloworld-ws-reference does use the binding.ws to wire to the
>> service exposed by the helloworld-ws-service sample.
>>
>> As for the ws binding, you can use it to consume services available on
>> the cloud, you can see this in the demos/xml-bigbank
>>
>>
>> On Thu, May 15, 2008 at 1:07 PM, Jean-Jacques Dubray <jd...@gmail.com>
>> wrote:
>> > Luciano has pointed me towards a BPEL reference sample. It was
>> constructed
>> > by using the HelloWord sample which "inovkes" a GreetingsService. The
>> > Greeting Service is a regular web service implemented as an SCA composite
>> > (similar to the hello-ws sample).
>> >
>> > The hello world bpel definition exposes itself a service.
>> >
>> > Even though GreetingsService is a plain vanilla Web Service its reference
>> > definition includes an implementation.java element:
>> >
>> >    <component name="GreetingsServiceComponent">
>> >        <implementation.java class="greetings.GreetingsServiceImpl" />
>> >
>> >        <service name="GreetingsService">
>> >            <interface.wsdl interface="
>> > http://greetings#wsdl.interface(Greetings)<http://greetings#wsdl.interface%28Greetings%29>"
>> />
>> >        </service>
>> >    </component>
>> >
>> > this is also true for the helloworld-ws-reference sample:
>> >
>> >    <reference name="HelloWorldService"
>> > promote="HelloWorldServiceComponent/helloWorldService">
>> >        <interface.java interface="helloworld.HelloWorldService" />
>> >        <binding.ws wsdlElement="
>> > http://helloworld#wsdl.port(HelloWorldService/HelloWorldSoapPort)<http://helloworld#wsdl.port%28HelloWorldService/HelloWorldSoapPort%29>
>> "/>
>> >    </reference>
>> >
>> > Why is not a WSDL enough?
>> >
>> > The other question is if you use a WS binding, why does the service has
>> to
>> > be part of the same domain as the consumers? Could they belong to two
>> > different SCA domains? As a matter of fact can a composite consume a WSDL
>> > reference that is not part of an SCA domain at all?
>> >
>> > thanks,
>> >
>> > --
>> > Jean-Jacques Dubray
>> > 425-445-4467
>> >
>>
>>
>>
>> --
>> Luciano Resende
>> Apache Tuscany Committer
>> http://people.apache.org/~lresende <http://people.apache.org/%7Elresende>
>> http://lresende.blogspot.com/
>>
>
>
>
> --
> Jean-Jacques Dubray
> 425-445-4467
>



-- 
Luciano Resende
Apache Tuscany Committer
http://people.apache.org/~lresende
http://lresende.blogspot.com/

RE: error: SCA Composite Desinger with Tuscany

Posted by Mukhtiar Memon <me...@hotmail.com>.
Hi,
 
Thanks for your reply. The composite file is here:
 
Restaurant.composite:
_________________________________________________________________________________
 
<?xml version="1.0" encoding="UTF-8"?>
<sca:composite xmlns:sca="http://www.osoa.org/xmlns/sca/1.0"
xmlns:tuscany="http://tuscany.apachi.org/xmlns/sca/1.0" name="Restaurant">
<sca:component name="RestaurantServiceComponent">
<sca:implementation.java class="restaurant.lib.RestaurantServiceImpl"/>
<sca:service name="RestaurantService">
<sca:interface.java interface="restaurant.api.RestaurantService"/>
<tuscany:binding.rmi host="localhost" port="8099" serviceName="RestaurantRMIService"/>
</sca:service>

<sca:reference name="billService"/>
<sca:reference name="menuService"/>
</sca:component>
<sca:service name="RestaurantService" promote="RestaurantServiceComponent/RestaurantService"/>
<sca:component name="BillServiceComponent">
<sca:implementation.java class="restaurant.lib.BillServiceImpl"/>
<sca:service name="BillService">
<sca:interface.java interface="restaurant.api.BillService"/>
</sca:service>
<sca:reference name="vatService"/>
<sca:reference name="tipService"/>
</sca:component>
<sca:component name="MenuServiceComponent">
<sca:implementation.java class="restaurant.lib.MenuServiceImpl"/>
<sca:service name="MenuService">
<sca:interface.java interface="restaurant.api.MenuService"/>
</sca:service>
</sca:component>
<sca:component name="VatServiceComponent">
<sca:implementation.java class="restaurant.lib.VatServiceImpl"/>
<sca:service name="VatService">
<sca:interface.java interface="restaurant.api.VatService"/>
</sca:service>
</sca:component>
<sca:component name="TipServiceComponent">
<sca:implementation.java class="restaurant.lib.TipServiceImpl"/>
<sca:service name="TipService">
<sca:interface.java interface="restaurant.api.TipService"/>
</sca:service>
</sca:component>
<sca:wire source="RestaurantServiceComponent/menuService" target="MenuServiceComponent/MenuService"/>
<sca:wire source="BillServiceComponent/tipService" target="TipServiceComponent/TipService"/>
<sca:wire source="BillServiceComponent/vatService" target="VatServiceComponent/VatService"/>
<sca:wire source="RestaurantServiceComponent/billService" target="BillServiceComponent/BillService"/>
</sca:composite>
_____________________________________________________________________________________
 
Thanks
 
Mukhtiar
> Date: Sun, 25 May 2008 10:55:47 +0200> From: stdrapeau@gmail.com> To: tuscany-user@ws.apache.org> Subject: Re: error: SCA Composite Desinger with Tuscany> > Hi,> > Perhaps a problem with the name of your references and your services.> Can you send the composite file?> > Stéphane Drapeau> Obeo> > On Fri, May 23, 2008 at 10:47 AM, Mukhtiar Memon <me...@hotmail.com>> wrote:> > >> > Hi,> >> > I am trying to run the Restaurant example using Tuscany Library with SOA> > Tools Platfrom (STP) Tool for SCA Composite Desinger. The link for the> > tutorial is:> >> > http://wiki.eclipse.org/images/6/61/FirstStepsWithTheSCADesigner.pdf> >> > All goes well but in the end when I execute the test Client.jave, I get> > following error. Please guide if you know about the problem. The error is:> >> >> > _________________________________________________________________________________> > May 23, 2008 10:35:23 AM> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem> > WARNING: Component reference target not found, it might be a remote> > service: VatService> > May 23, 2008 10:35:23 AM> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem> > WARNING: Component reference target not found, it might be a remote> > service: MenuService> > May 23, 2008 10:35:23 AM> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem> > WARNING: Component reference target not found, it might be a remote> > service: TipService> > May 23, 2008 10:35:23 AM> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem> > WARNING: Component reference target not found, it might be a remote> > service: BillService> > Exception in thread "main" org.osoa.sca.ServiceUnavailableException: No> > service invoker is available for reference menuService (bindingURI=null> > operation=getPrice).> > at> > org.apache.tuscany.sca.binding.sca.impl.RuntimeSCAReferenceBindingProvider.createInvoker(RuntimeSCAReferenceBindingProvider.java:192)> > at> > org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.addBindingInterceptor(RuntimeWireImpl.java:214)> > at> > org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.initInvocationChains(RuntimeWireImpl.java:156)> > at> > org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.getInvocationChains(RuntimeWireImpl.java:97)> > at> > org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.getInvocationChain(JDKInvocationHandler.java:190)> > at> > org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:124)> > at $Proxy8.getMenu(Unknown Source)> > at> > restaurant.lib.RestaurantServiceImpl.getMenus(RestaurantServiceImpl.java:26)> > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)> > at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)> > at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)> > at java.lang.reflect.Method.invoke(Unknown Source)> > at> > org.apache.tuscany.sca.implementation.java.invocation.JavaImplementationInvoker.invoke(JavaImplementationInvoker.java:105)> > at> > org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:233)> > at> > org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:130)> > at $Proxy7.getMenus(Unknown Source)> > at test.Client.main(Client.java:11)> >> > _________________________________________________________________________________> >> >> > Thanks> >> > Mukhtiar
_________________________________________________________________
Change the world with e-mail. Join the i’m Initiative from Microsoft.
http://im.live.com/Messenger/IM/Join/Default.aspx?source=EML_WL_ChangeWorld

Re: error: SCA Composite Desinger with Tuscany

Posted by Stéphane Drapeau <st...@gmail.com>.
Hi,

Perhaps a problem with the name of your references and your services.
Can you send the composite file?

Stéphane Drapeau
Obeo

On Fri, May 23, 2008 at 10:47 AM, Mukhtiar Memon <me...@hotmail.com>
wrote:

>
> Hi,
>
> I am trying to run the Restaurant example using Tuscany Library with SOA
> Tools Platfrom (STP) Tool for SCA Composite Desinger. The link for the
> tutorial is:
>
> http://wiki.eclipse.org/images/6/61/FirstStepsWithTheSCADesigner.pdf
>
> All goes well but in the end when I execute the test Client.jave, I get
> following error. Please guide if you know about the problem. The error is:
>
>
> _________________________________________________________________________________
> May 23, 2008 10:35:23 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
> WARNING: Component reference target not found, it might be a remote
> service: VatService
> May 23, 2008 10:35:23 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
> WARNING: Component reference target not found, it might be a remote
> service: MenuService
> May 23, 2008 10:35:23 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
> WARNING: Component reference target not found, it might be a remote
> service: TipService
> May 23, 2008 10:35:23 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
> WARNING: Component reference target not found, it might be a remote
> service: BillService
> Exception in thread "main" org.osoa.sca.ServiceUnavailableException: No
> service invoker is available for reference menuService (bindingURI=null
> operation=getPrice).
> at
> org.apache.tuscany.sca.binding.sca.impl.RuntimeSCAReferenceBindingProvider.createInvoker(RuntimeSCAReferenceBindingProvider.java:192)
> at
> org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.addBindingInterceptor(RuntimeWireImpl.java:214)
> at
> org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.initInvocationChains(RuntimeWireImpl.java:156)
> at
> org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.getInvocationChains(RuntimeWireImpl.java:97)
> at
> org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.getInvocationChain(JDKInvocationHandler.java:190)
> at
> org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:124)
> at $Proxy8.getMenu(Unknown Source)
> at
> restaurant.lib.RestaurantServiceImpl.getMenus(RestaurantServiceImpl.java:26)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at
> org.apache.tuscany.sca.implementation.java.invocation.JavaImplementationInvoker.invoke(JavaImplementationInvoker.java:105)
> at
> org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:233)
> at
> org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:130)
> at $Proxy7.getMenus(Unknown Source)
> at test.Client.main(Client.java:11)
>
> _________________________________________________________________________________
>
>
> Thanks
>
> Mukhtiar

error: SCA Composite Desinger with Tuscany

Posted by Mukhtiar Memon <me...@hotmail.com>.
Hi,
 
I am trying to run the Restaurant example using Tuscany Library with SOA Tools Platfrom (STP) Tool for SCA Composite Desinger. The link for the tutorial is: 
 
http://wiki.eclipse.org/images/6/61/FirstStepsWithTheSCADesigner.pdf
 
All goes well but in the end when I execute the test Client.jave, I get following error. Please guide if you know about the problem. The error is:
 
_________________________________________________________________________________
May 23, 2008 10:35:23 AM org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
WARNING: Component reference target not found, it might be a remote service: VatService
May 23, 2008 10:35:23 AM org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
WARNING: Component reference target not found, it might be a remote service: MenuService
May 23, 2008 10:35:23 AM org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
WARNING: Component reference target not found, it might be a remote service: TipService
May 23, 2008 10:35:23 AM org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
WARNING: Component reference target not found, it might be a remote service: BillService
Exception in thread "main" org.osoa.sca.ServiceUnavailableException: No service invoker is available for reference menuService (bindingURI=null operation=getPrice).
at org.apache.tuscany.sca.binding.sca.impl.RuntimeSCAReferenceBindingProvider.createInvoker(RuntimeSCAReferenceBindingProvider.java:192)
at org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.addBindingInterceptor(RuntimeWireImpl.java:214)
at org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.initInvocationChains(RuntimeWireImpl.java:156)
at org.apache.tuscany.sca.core.assembly.RuntimeWireImpl.getInvocationChains(RuntimeWireImpl.java:97)
at org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.getInvocationChain(JDKInvocationHandler.java:190)
at org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:124)
at $Proxy8.getMenu(Unknown Source)
at restaurant.lib.RestaurantServiceImpl.getMenus(RestaurantServiceImpl.java:26)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.tuscany.sca.implementation.java.invocation.JavaImplementationInvoker.invoke(JavaImplementationInvoker.java:105)
at org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:233)
at org.apache.tuscany.sca.core.invocation.JDKInvocationHandler.invoke(JDKInvocationHandler.java:130)
at $Proxy7.getMenus(Unknown Source)
at test.Client.main(Client.java:11)
_________________________________________________________________________________
 
 
Thanks
 
Mukhtiar
> Date: Thu, 22 May 2008 09:06:26 -0700> From: luckbr1975@gmail.com> To: tuscany-user@ws.apache.org> Subject: Re: Web Service References> > Would you mind creating a JIRA and posting at least your composite,> wsdl and deploy.xml files so i can take a look.> > On Thu, May 22, 2008 at 9:00 AM, Jean-Jacques Dubray <jd...@gmail.com> wrote:> > Good point, I removed the "tuscany" namespace that had been added by the> > Composite Editor and the errors are gone> >> > I do get however:> > [java] Starting setup> > [java] [INFO] - GeronimoLog.info(79) | Using embedded Geronimo> > transaction manager> > [java] java.lang.NullPointerException> >> > The same behavior is true whether I use:> > <interface.wsdl interface="> > http://192.168.2.2:8085/GreetingsService#wsdl.interface(Greetings)"/>> >> > or <interface.wsdl interface="> > http://192.168.2.2:8085/GreetingsService#wsdl.portType(Greetings)"/>> >> >> > JJ-> >> > On Thu, May 22, 2008 at 8:49 AM, Luciano Resende <lu...@gmail.com>> > wrote:> >> >> The errors you are getting usually means that the necessary> >> dependencies that register processors to parse those elements are not> >> available (e.g implementation.bpel and interface.wsdl).> >>> >> On Thu, May 22, 2008 at 8:11 AM, Jean-Jacques Dubray <jd...@gmail.com>> >> wrote:> >> > Mike:> >> >> >> > I don't know if you are talking about this sample:> >> >> >> https://svn.apache.org/repos/asf/incubator/tuscany/java/sca/samples/helloworld-bpel-ws/> >> >> >> > If it's the case, the helloworld.composite does not have a reference, it> >> > simply exposes a BPEL implementation as a service.> >> >> >> > I think I understand a bit better the rationale for not modeling external> >> > references as "components" and why "components" need to have an> >> > implementation. I am fine with it since a component must belong to a> >> domain.> >> >> >> >> >> > I have tried to do some cross-domain work by modeling a service (external> >> to> >> > the domain) invoked by a BPEL implementation and I get some errors. I> >> don't> >> > know if anyone could help me.> >> >> >> > Here is my composite file (I replaced the GreetingsService component by a> >> > reference to an external web service (implemented in a different> >> domain)):> >> >> >> > <?xml version="1.0" encoding="ISO-8859-15"?>> >> > <composite xmlns="http://www.osoa.org/xmlns/sca/1.0" xmlns:sca="> >> > http://www.osoa.org/xmlns/sca/1.0" xmlns:hns="http://helloworld"> >> > xmlns:instance="http://www.w3.org/2004/08/wsdl-instance" xmlns:tuscany="> >> > http://tuscany.apache.org/xmlns/sca/1.0" name="helloworld"> >> targetNamespace="> >> > http://bpel">> >> > <component name="HelloWorldService">> >> > <tuscany:implementation.bpel process="hns:HelloWorld"/>> >> > <reference name="greetingsPartnerLink" />> >> > </component>> >> > <reference name="GreetingsService"> >> > promote="HelloWorldService/greetingsPartnerLink">> >> > <tuscany:interface.wsdl interface="> >> > http://laptop2:8085/GreetingsService#wsdl.portType(Greetings)<http://laptop2:8085/GreetingsService#wsdl.portType%28Greetings%29>> >> "/>> >> > <binding.ws wsdlElement="> >> > http://laptop2:8085/GreetingsService#wsdl.service(GreetingsService)<http://laptop2:8085/GreetingsService#wsdl.service%28GreetingsService%29>> >> "> >> > instance:wsdlLocation="http://laptop2:8085/GreetingsService.wsdl"/>> >> > </reference>> >> > </composite>> >> >> >> > I do get a series of errors coming from the domain trying to implement> >> this> >> > composite:> >> >> >> > [java] May 22, 2008 7:44:59 AM> >> >> >> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor> >> > read> >> > [java] WARNING: Element {> >> > http://tuscany.apache.org/xmlns/sca/1.0}implementation.bpel<http://tuscany.apache.org/xmlns/sca/1.0%7Dimplementation.bpel>cannot be> >> > processed. ([row,col {unknown-source}]: [4,5])> >> > [java] May 22, 2008 7:44:59 AM> >> >> >> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor> >> > read> >> > [java] WARNING: Element {> >> > http://tuscany.apache.org/xmlns/sca/1.0}interface.wsdl<http://tuscany.apache.org/xmlns/sca/1.0%7Dinterface.wsdl>cannot be processed.> >> > ([row,col {unknown-source}]: [8,5])> >> > [java] May 22, 2008 7:44:59 AM> >> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1> >> problem> >> > [java] WARNING: No implementation for component: HelloWorldService> >> > [java] May 22, 2008 7:44:59 AM> >> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1> >> problem> >> > [java] WARNING: Reference not found for component reference:> >> > HelloWorldService/greetingsPartnerLink> >> > [java] May 22, 2008 7:44:59 AM> >> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1> >> problem> >> > [java] WARNING: No implementation for component: HelloWorldService> >> > [java] May 22, 2008 7:44:59 AM> >> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1> >> problem> >> > [java] WARNING: Reference not found for component reference:> >> > HelloWorldService/greetingsPartnerLink> >> > [java] No service is declared on component HelloWorldService> >> >> >> > BTW, of course the greetings service is up and running and I can query> >> its> >> > WSDL (v1.1)> >> >> >> > In the composite I did try both wsdl.interface and wsdl.portType and got> >> the> >> > same result (same interface.wsdl cannot be processed)> >> >> >> > thanks,> >> >> >> > JJ-> >> >> >> >> >> >> >> >> >> >> >> > On Sat, May 17, 2008 at 7:29 AM, Jean-Jacques Dubray <jd...@gmail.com>> >> > wrote:> >> >> >> >> Luciano, Mike:> >> >>> >> >> thanks for the detailed answer. Yes, I am aware there are different> >> types.> >> >> I am not so concerned having to declare an implementation within the> >> same> >> >> domain. As a matter of fact, it looks to me that it is not even within> >> an> >> >> entire domain, but within a composite since there is an implementation> >> type> >> >> which is "implementation.composite", so the scope to which an> >> implementation> >> >> declaration is exposed is fairly limited (which is good).> >> >>> >> >> I am more concerned of "cross domain" interactions and in particular> >> how,> >> >> say, a .Net based web service gets "assembled". In that case you won't> >> be> >> >> able to find a valid implementation to expose as a composite. In "cross> >> >> domain" interactions you are also left to use Web Services technologies> >> >> (which I'm fine with, it'd be a shame to find no real use for WS-* after> >> all> >> >> this energy spent :-).> >> >>> >> >> Do you have a sample for that use case?> >> >>> >> >> thanks,> >> >>> >> >> JJ-> >> >>> >> >>> >> >> On Sat, May 17, 2008 at 5:34 AM, Mike Edwards <> >> >> mike.edwards.inglenook@gmail.com> wrote:> >> >>> >> >>> Jean-Jacques Dubray wrote:> >> >>>> >> >>>> Luciano:> >> >>>>> >> >>>> thanks, actually in the test/bpel/helloworld-reference composite> >> >>>> definition> >> >>>> you also have a component defined with a binding.ws and there to,> >> there> >> >>>> is> >> >>>> an implementation.java element. Is it required?> >> >>>>> >> >>>> <!-- Simple ws-reference -->> >> >>>> <!--> >> >>>> <component name="HelloWorldService">> >> >>>> <implementation.java class="helloworld.HelloWorldServiceImpl"/>> >> >>>> <reference name="greetingsService">> >> >>>> <binding.ws uri="http://localhost:8085/GreetingsService"/>> >> >>>> </reference>> >> >>>> </component>> >> >>>> -->> >> >>>>> >> >>>> Would you consider ws bindings as the preferred way to implement> >> cross> >> >>>> domain composites?> >> >>>>> >> >>>> JJ-> >> >>>>> >> >>>> Jean-Jacques,> >> >>>> >> >>> There may be a misunderstanding going on here....> >> >>>> >> >>> Where there is a component in SCA, that says that there is a piece of> >> code> >> >>> present which implements some function - and that the code provides> >> function> >> >>> via one or more services and consumes function provided elsewhere> >> through> >> >>> zero or more references.> >> >>>> >> >>> That code is called an implementation - and the implementation can be> >> any> >> >>> one of many kinds - Java, BPEL, C++, JavaScript, Ruby, etc. But there> >> must> >> >>> be an implementation of some kind - and the component declaration is> >> obliged> >> >>> to point at one.> >> >>>> >> >>> In this case, the HelloWorldService component has an implementation> >> that> >> >>> is a Java POJO - the class> >> >>> helloworld.HelloWorldServiceImpl. While this test could have used some> >> >>> other implementation type such as BPEL, it IS required to have SOME> >> >>> implementation - otherwise there is no function that the component can> >> >>> provide.> >> >>>> >> >>> The fact that the implementation is a Java POJO does not prevent the> >> >>> service interface or the reference interface being declared using WSDL> >> and> >> >>> it also does not prevent the service or reference using a binding that> >> is a> >> >>> Web service binding also using a WSDL, should that be desirable.> >> >>>> >> >>> Here is a simple example of a component implemented by a BPEL process> >> and> >> >>> exposed as a Web service:> >> >>>> >> >>> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"> >> >>> targetNamespace="http://bpel"> >> >>> xmlns:hns="> >> >>> http://tuscany.apache.org/implementation/bpel/example/helloworld"> >> >>> name="bpel">> >> >>>> >> >>> <component name="BPELHelloWorldComponent">> >> >>> <implementation.bpel process="hns:HelloWorld"/>> >> >>> <service name="helloPartnerLink">> >> >>> <interface.wsdl> >> >>> interface="> >> >>> http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl#> >> >>> wsdl.interface(HelloPortType)" />> >> >>> <binding.ws />> >> >>> </service>> >> >>> </component>> >> >>>> >> >>> </composite>> >> >>>> >> >>> ....no Java in sight !> >> >>>> >> >>> PS - you will find that component in a new BPEL Sample I've recently> >> >>> committed to the Tuscany SVN - called "helloworld-bpel-ws".> >> >>>> >> >>> Yours, Mike.> >> >>>> >> >>> >> >>> >> >>> >> >> --> >> >> Jean-Jacques Dubray> >> >> 425-445-4467> >> >>> >> >> >> >> >> >> >> > --> >> > Jean-Jacques Dubray> >> > 425-445-4467> >> >> >>> >>> >>> >> --> >> Luciano Resende> >> Apache Tuscany Committer> >> http://people.apache.org/~lresende <http://people.apache.org/%7Elresende>> >> http://lresende.blogspot.com/> >>> >> >> >> > --> > Jean-Jacques Dubray> > 425-445-4467> >> > > > -- > Luciano Resende> Apache Tuscany Committer> http://people.apache.org/~lresende> http://lresende.blogspot.com/
_________________________________________________________________
Keep your kids safer online with Windows Live Family Safety.
http://www.windowslive.com/family_safety/overview.html?ocid=TXT_TAGLM_WL_Refresh_family_safety_052008

Re: Web Service References

Posted by Luciano Resende <lu...@gmail.com>.
Would you mind creating a JIRA and posting at least your composite,
wsdl and deploy.xml files so i can take a look.

On Thu, May 22, 2008 at 9:00 AM, Jean-Jacques Dubray <jd...@gmail.com> wrote:
> Good point, I removed the "tuscany" namespace that had been added by the
> Composite Editor and the errors are gone
>
> I do get however:
>     [java] Starting setup
>     [java] [INFO] - GeronimoLog.info(79) | Using embedded Geronimo
> transaction manager
>     [java] java.lang.NullPointerException
>
> The same behavior is true whether I use:
>  <interface.wsdl interface="
> http://192.168.2.2:8085/GreetingsService#wsdl.interface(Greetings)"/>
>
> or  <interface.wsdl interface="
> http://192.168.2.2:8085/GreetingsService#wsdl.portType(Greetings)"/>
>
>
> JJ-
>
> On Thu, May 22, 2008 at 8:49 AM, Luciano Resende <lu...@gmail.com>
> wrote:
>
>> The errors you are getting usually means that the necessary
>> dependencies that register processors to parse those elements are not
>> available (e.g implementation.bpel and interface.wsdl).
>>
>> On Thu, May 22, 2008 at 8:11 AM, Jean-Jacques Dubray <jd...@gmail.com>
>> wrote:
>> > Mike:
>> >
>> > I don't know if you are talking about this sample:
>> >
>> https://svn.apache.org/repos/asf/incubator/tuscany/java/sca/samples/helloworld-bpel-ws/
>> >
>> > If it's the case, the helloworld.composite does not have a reference, it
>> > simply exposes a BPEL implementation as a service.
>> >
>> > I think I understand a bit better the rationale for not modeling external
>> > references as "components" and why "components" need to have an
>> > implementation. I am fine with it since a component must belong to a
>> domain.
>> >
>> >
>> > I have tried to do some cross-domain work by modeling a service (external
>> to
>> > the domain) invoked by a BPEL implementation and I get some errors. I
>> don't
>> > know if anyone could help me.
>> >
>> > Here is my composite file (I replaced the GreetingsService component by a
>> > reference to an external web service (implemented in a different
>> domain)):
>> >
>> > <?xml version="1.0" encoding="ISO-8859-15"?>
>> > <composite xmlns="http://www.osoa.org/xmlns/sca/1.0" xmlns:sca="
>> > http://www.osoa.org/xmlns/sca/1.0" xmlns:hns="http://helloworld"
>> > xmlns:instance="http://www.w3.org/2004/08/wsdl-instance" xmlns:tuscany="
>> > http://tuscany.apache.org/xmlns/sca/1.0" name="helloworld"
>> targetNamespace="
>> > http://bpel">
>> >  <component name="HelloWorldService">
>> >    <tuscany:implementation.bpel process="hns:HelloWorld"/>
>> >    <reference name="greetingsPartnerLink" />
>> >  </component>
>> >  <reference name="GreetingsService"
>> > promote="HelloWorldService/greetingsPartnerLink">
>> >    <tuscany:interface.wsdl interface="
>> > http://laptop2:8085/GreetingsService#wsdl.portType(Greetings)<http://laptop2:8085/GreetingsService#wsdl.portType%28Greetings%29>
>> "/>
>> >    <binding.ws wsdlElement="
>> > http://laptop2:8085/GreetingsService#wsdl.service(GreetingsService)<http://laptop2:8085/GreetingsService#wsdl.service%28GreetingsService%29>
>> "
>> > instance:wsdlLocation="http://laptop2:8085/GreetingsService.wsdl"/>
>> >  </reference>
>> > </composite>
>> >
>> > I do get a series of errors coming from the domain trying to implement
>> this
>> > composite:
>> >
>> > [java] May 22, 2008 7:44:59 AM
>> >
>> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
>> > read
>> >     [java] WARNING: Element {
>> > http://tuscany.apache.org/xmlns/sca/1.0}implementation.bpel<http://tuscany.apache.org/xmlns/sca/1.0%7Dimplementation.bpel>cannot be
>> > processed. ([row,col {unknown-source}]: [4,5])
>> >     [java] May 22, 2008 7:44:59 AM
>> >
>> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
>> > read
>> >     [java] WARNING: Element {
>> > http://tuscany.apache.org/xmlns/sca/1.0}interface.wsdl<http://tuscany.apache.org/xmlns/sca/1.0%7Dinterface.wsdl>cannot be processed.
>> > ([row,col {unknown-source}]: [8,5])
>> >     [java] May 22, 2008 7:44:59 AM
>> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
>> problem
>> >     [java] WARNING: No implementation for component: HelloWorldService
>> >     [java] May 22, 2008 7:44:59 AM
>> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
>> problem
>> >     [java] WARNING: Reference not found for component reference:
>> > HelloWorldService/greetingsPartnerLink
>> >     [java] May 22, 2008 7:44:59 AM
>> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
>> problem
>> >     [java] WARNING: No implementation for component: HelloWorldService
>> >     [java] May 22, 2008 7:44:59 AM
>> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
>> problem
>> >     [java] WARNING: Reference not found for component reference:
>> > HelloWorldService/greetingsPartnerLink
>> >     [java] No service is declared on component HelloWorldService
>> >
>> > BTW, of course the greetings service is up and running and I can query
>> its
>> > WSDL (v1.1)
>> >
>> > In the composite I did try both wsdl.interface and wsdl.portType and got
>> the
>> > same result (same interface.wsdl cannot be processed)
>> >
>> > thanks,
>> >
>> > JJ-
>> >
>> >
>> >
>> >
>> >
>> > On Sat, May 17, 2008 at 7:29 AM, Jean-Jacques Dubray <jd...@gmail.com>
>> > wrote:
>> >
>> >> Luciano, Mike:
>> >>
>> >> thanks for the detailed answer. Yes, I am aware there are different
>> types.
>> >> I am not so concerned having to declare an implementation within the
>> same
>> >> domain. As a matter of fact, it looks to me that it is not even within
>> an
>> >> entire domain, but within a composite since there is an implementation
>> type
>> >> which is "implementation.composite", so the scope to which an
>> implementation
>> >> declaration is exposed is fairly limited (which is good).
>> >>
>> >> I am more concerned of "cross domain" interactions and in particular
>> how,
>> >> say, a .Net based web service gets "assembled". In that case you won't
>> be
>> >> able to find a valid implementation to expose as a composite. In "cross
>> >> domain" interactions you are also left to use Web Services technologies
>> >> (which I'm fine with, it'd be a shame to find no real use for WS-* after
>> all
>> >> this energy spent :-).
>> >>
>> >> Do you have a sample for that use case?
>> >>
>> >> thanks,
>> >>
>> >> JJ-
>> >>
>> >>
>> >> On Sat, May 17, 2008 at 5:34 AM, Mike Edwards <
>> >> mike.edwards.inglenook@gmail.com> wrote:
>> >>
>> >>> Jean-Jacques Dubray wrote:
>> >>>
>> >>>> Luciano:
>> >>>>
>> >>>> thanks, actually in the test/bpel/helloworld-reference composite
>> >>>> definition
>> >>>> you also have a component defined with a binding.ws and there to,
>> there
>> >>>> is
>> >>>> an implementation.java element. Is it required?
>> >>>>
>> >>>> <!-- Simple ws-reference -->
>> >>>>    <!--
>> >>>>    <component name="HelloWorldService">
>> >>>>        <implementation.java class="helloworld.HelloWorldServiceImpl"/>
>> >>>>        <reference name="greetingsService">
>> >>>>            <binding.ws uri="http://localhost:8085/GreetingsService"/>
>> >>>>        </reference>
>> >>>>    </component>
>> >>>>    -->
>> >>>>
>> >>>> Would you consider ws bindings as the preferred way to implement
>>  cross
>> >>>> domain composites?
>> >>>>
>> >>>> JJ-
>> >>>>
>> >>>>  Jean-Jacques,
>> >>>
>> >>> There may be a misunderstanding going on here....
>> >>>
>> >>> Where there is a component in SCA, that says that there is a piece of
>> code
>> >>> present which implements some function - and that the code provides
>> function
>> >>> via one or more services and consumes function provided elsewhere
>> through
>> >>> zero or more references.
>> >>>
>> >>> That code is called an implementation - and the implementation can be
>> any
>> >>> one of many kinds - Java, BPEL, C++, JavaScript, Ruby, etc.  But there
>> must
>> >>> be an implementation of some kind - and the component declaration is
>> obliged
>> >>> to point at one.
>> >>>
>> >>> In this case, the HelloWorldService component has an implementation
>> that
>> >>> is a Java POJO - the class
>> >>> helloworld.HelloWorldServiceImpl.  While this test could have used some
>> >>> other implementation type such as BPEL, it IS required to have SOME
>> >>> implementation - otherwise there is no function that the component can
>> >>> provide.
>> >>>
>> >>> The fact that the implementation is a Java POJO does not prevent the
>> >>> service interface or the reference interface being declared using WSDL
>> and
>> >>> it also does not prevent the service or reference using a binding that
>> is a
>> >>> Web service binding also using a WSDL, should that be desirable.
>> >>>
>> >>> Here is a simple example of a component implemented by a BPEL process
>> and
>> >>> exposed as a Web service:
>> >>>
>> >>> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
>> >>>    targetNamespace="http://bpel"
>> >>>    xmlns:hns="
>> >>> http://tuscany.apache.org/implementation/bpel/example/helloworld"
>> >>>    name="bpel">
>> >>>
>> >>>    <component name="BPELHelloWorldComponent">
>> >>>        <implementation.bpel process="hns:HelloWorld"/>
>> >>>        <service name="helloPartnerLink">
>> >>>            <interface.wsdl
>> >>>                 interface="
>> >>> http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl#
>> >>>                 wsdl.interface(HelloPortType)" />
>> >>>            <binding.ws />
>> >>>        </service>
>> >>>    </component>
>> >>>
>> >>> </composite>
>> >>>
>> >>> ....no Java in sight !
>> >>>
>> >>> PS - you will find that component in a new BPEL Sample I've recently
>> >>> committed to the Tuscany SVN - called  "helloworld-bpel-ws".
>> >>>
>> >>> Yours,  Mike.
>> >>>
>> >>
>> >>
>> >>
>> >> --
>> >> Jean-Jacques Dubray
>> >> 425-445-4467
>> >>
>> >
>> >
>> >
>> > --
>> > Jean-Jacques Dubray
>> > 425-445-4467
>> >
>>
>>
>>
>> --
>> Luciano Resende
>> Apache Tuscany Committer
>> http://people.apache.org/~lresende <http://people.apache.org/%7Elresende>
>> http://lresende.blogspot.com/
>>
>
>
>
> --
> Jean-Jacques Dubray
> 425-445-4467
>



-- 
Luciano Resende
Apache Tuscany Committer
http://people.apache.org/~lresende
http://lresende.blogspot.com/

Re: Web Service References

Posted by Jean-Jacques Dubray <jd...@gmail.com>.
Good point, I removed the "tuscany" namespace that had been added by the
Composite Editor and the errors are gone

I do get however:
     [java] Starting setup
     [java] [INFO] - GeronimoLog.info(79) | Using embedded Geronimo
transaction manager
     [java] java.lang.NullPointerException

The same behavior is true whether I use:
 <interface.wsdl interface="
http://192.168.2.2:8085/GreetingsService#wsdl.interface(Greetings)"/>

or  <interface.wsdl interface="
http://192.168.2.2:8085/GreetingsService#wsdl.portType(Greetings)"/>


JJ-

On Thu, May 22, 2008 at 8:49 AM, Luciano Resende <lu...@gmail.com>
wrote:

> The errors you are getting usually means that the necessary
> dependencies that register processors to parse those elements are not
> available (e.g implementation.bpel and interface.wsdl).
>
> On Thu, May 22, 2008 at 8:11 AM, Jean-Jacques Dubray <jd...@gmail.com>
> wrote:
> > Mike:
> >
> > I don't know if you are talking about this sample:
> >
> https://svn.apache.org/repos/asf/incubator/tuscany/java/sca/samples/helloworld-bpel-ws/
> >
> > If it's the case, the helloworld.composite does not have a reference, it
> > simply exposes a BPEL implementation as a service.
> >
> > I think I understand a bit better the rationale for not modeling external
> > references as "components" and why "components" need to have an
> > implementation. I am fine with it since a component must belong to a
> domain.
> >
> >
> > I have tried to do some cross-domain work by modeling a service (external
> to
> > the domain) invoked by a BPEL implementation and I get some errors. I
> don't
> > know if anyone could help me.
> >
> > Here is my composite file (I replaced the GreetingsService component by a
> > reference to an external web service (implemented in a different
> domain)):
> >
> > <?xml version="1.0" encoding="ISO-8859-15"?>
> > <composite xmlns="http://www.osoa.org/xmlns/sca/1.0" xmlns:sca="
> > http://www.osoa.org/xmlns/sca/1.0" xmlns:hns="http://helloworld"
> > xmlns:instance="http://www.w3.org/2004/08/wsdl-instance" xmlns:tuscany="
> > http://tuscany.apache.org/xmlns/sca/1.0" name="helloworld"
> targetNamespace="
> > http://bpel">
> >  <component name="HelloWorldService">
> >    <tuscany:implementation.bpel process="hns:HelloWorld"/>
> >    <reference name="greetingsPartnerLink" />
> >  </component>
> >  <reference name="GreetingsService"
> > promote="HelloWorldService/greetingsPartnerLink">
> >    <tuscany:interface.wsdl interface="
> > http://laptop2:8085/GreetingsService#wsdl.portType(Greetings)<http://laptop2:8085/GreetingsService#wsdl.portType%28Greetings%29>
> "/>
> >    <binding.ws wsdlElement="
> > http://laptop2:8085/GreetingsService#wsdl.service(GreetingsService)<http://laptop2:8085/GreetingsService#wsdl.service%28GreetingsService%29>
> "
> > instance:wsdlLocation="http://laptop2:8085/GreetingsService.wsdl"/>
> >  </reference>
> > </composite>
> >
> > I do get a series of errors coming from the domain trying to implement
> this
> > composite:
> >
> > [java] May 22, 2008 7:44:59 AM
> >
> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
> > read
> >     [java] WARNING: Element {
> > http://tuscany.apache.org/xmlns/sca/1.0}implementation.bpel<http://tuscany.apache.org/xmlns/sca/1.0%7Dimplementation.bpel>cannot be
> > processed. ([row,col {unknown-source}]: [4,5])
> >     [java] May 22, 2008 7:44:59 AM
> >
> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
> > read
> >     [java] WARNING: Element {
> > http://tuscany.apache.org/xmlns/sca/1.0}interface.wsdl<http://tuscany.apache.org/xmlns/sca/1.0%7Dinterface.wsdl>cannot be processed.
> > ([row,col {unknown-source}]: [8,5])
> >     [java] May 22, 2008 7:44:59 AM
> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
> problem
> >     [java] WARNING: No implementation for component: HelloWorldService
> >     [java] May 22, 2008 7:44:59 AM
> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
> problem
> >     [java] WARNING: Reference not found for component reference:
> > HelloWorldService/greetingsPartnerLink
> >     [java] May 22, 2008 7:44:59 AM
> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
> problem
> >     [java] WARNING: No implementation for component: HelloWorldService
> >     [java] May 22, 2008 7:44:59 AM
> > org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1
> problem
> >     [java] WARNING: Reference not found for component reference:
> > HelloWorldService/greetingsPartnerLink
> >     [java] No service is declared on component HelloWorldService
> >
> > BTW, of course the greetings service is up and running and I can query
> its
> > WSDL (v1.1)
> >
> > In the composite I did try both wsdl.interface and wsdl.portType and got
> the
> > same result (same interface.wsdl cannot be processed)
> >
> > thanks,
> >
> > JJ-
> >
> >
> >
> >
> >
> > On Sat, May 17, 2008 at 7:29 AM, Jean-Jacques Dubray <jd...@gmail.com>
> > wrote:
> >
> >> Luciano, Mike:
> >>
> >> thanks for the detailed answer. Yes, I am aware there are different
> types.
> >> I am not so concerned having to declare an implementation within the
> same
> >> domain. As a matter of fact, it looks to me that it is not even within
> an
> >> entire domain, but within a composite since there is an implementation
> type
> >> which is "implementation.composite", so the scope to which an
> implementation
> >> declaration is exposed is fairly limited (which is good).
> >>
> >> I am more concerned of "cross domain" interactions and in particular
> how,
> >> say, a .Net based web service gets "assembled". In that case you won't
> be
> >> able to find a valid implementation to expose as a composite. In "cross
> >> domain" interactions you are also left to use Web Services technologies
> >> (which I'm fine with, it'd be a shame to find no real use for WS-* after
> all
> >> this energy spent :-).
> >>
> >> Do you have a sample for that use case?
> >>
> >> thanks,
> >>
> >> JJ-
> >>
> >>
> >> On Sat, May 17, 2008 at 5:34 AM, Mike Edwards <
> >> mike.edwards.inglenook@gmail.com> wrote:
> >>
> >>> Jean-Jacques Dubray wrote:
> >>>
> >>>> Luciano:
> >>>>
> >>>> thanks, actually in the test/bpel/helloworld-reference composite
> >>>> definition
> >>>> you also have a component defined with a binding.ws and there to,
> there
> >>>> is
> >>>> an implementation.java element. Is it required?
> >>>>
> >>>> <!-- Simple ws-reference -->
> >>>>    <!--
> >>>>    <component name="HelloWorldService">
> >>>>        <implementation.java class="helloworld.HelloWorldServiceImpl"/>
> >>>>        <reference name="greetingsService">
> >>>>            <binding.ws uri="http://localhost:8085/GreetingsService"/>
> >>>>        </reference>
> >>>>    </component>
> >>>>    -->
> >>>>
> >>>> Would you consider ws bindings as the preferred way to implement
>  cross
> >>>> domain composites?
> >>>>
> >>>> JJ-
> >>>>
> >>>>  Jean-Jacques,
> >>>
> >>> There may be a misunderstanding going on here....
> >>>
> >>> Where there is a component in SCA, that says that there is a piece of
> code
> >>> present which implements some function - and that the code provides
> function
> >>> via one or more services and consumes function provided elsewhere
> through
> >>> zero or more references.
> >>>
> >>> That code is called an implementation - and the implementation can be
> any
> >>> one of many kinds - Java, BPEL, C++, JavaScript, Ruby, etc.  But there
> must
> >>> be an implementation of some kind - and the component declaration is
> obliged
> >>> to point at one.
> >>>
> >>> In this case, the HelloWorldService component has an implementation
> that
> >>> is a Java POJO - the class
> >>> helloworld.HelloWorldServiceImpl.  While this test could have used some
> >>> other implementation type such as BPEL, it IS required to have SOME
> >>> implementation - otherwise there is no function that the component can
> >>> provide.
> >>>
> >>> The fact that the implementation is a Java POJO does not prevent the
> >>> service interface or the reference interface being declared using WSDL
> and
> >>> it also does not prevent the service or reference using a binding that
> is a
> >>> Web service binding also using a WSDL, should that be desirable.
> >>>
> >>> Here is a simple example of a component implemented by a BPEL process
> and
> >>> exposed as a Web service:
> >>>
> >>> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
> >>>    targetNamespace="http://bpel"
> >>>    xmlns:hns="
> >>> http://tuscany.apache.org/implementation/bpel/example/helloworld"
> >>>    name="bpel">
> >>>
> >>>    <component name="BPELHelloWorldComponent">
> >>>        <implementation.bpel process="hns:HelloWorld"/>
> >>>        <service name="helloPartnerLink">
> >>>            <interface.wsdl
> >>>                 interface="
> >>> http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl#
> >>>                 wsdl.interface(HelloPortType)" />
> >>>            <binding.ws />
> >>>        </service>
> >>>    </component>
> >>>
> >>> </composite>
> >>>
> >>> ....no Java in sight !
> >>>
> >>> PS - you will find that component in a new BPEL Sample I've recently
> >>> committed to the Tuscany SVN - called  "helloworld-bpel-ws".
> >>>
> >>> Yours,  Mike.
> >>>
> >>
> >>
> >>
> >> --
> >> Jean-Jacques Dubray
> >> 425-445-4467
> >>
> >
> >
> >
> > --
> > Jean-Jacques Dubray
> > 425-445-4467
> >
>
>
>
> --
> Luciano Resende
> Apache Tuscany Committer
> http://people.apache.org/~lresende <http://people.apache.org/%7Elresende>
> http://lresende.blogspot.com/
>



-- 
Jean-Jacques Dubray
425-445-4467

Re: Web Service References

Posted by Luciano Resende <lu...@gmail.com>.
The errors you are getting usually means that the necessary
dependencies that register processors to parse those elements are not
available (e.g implementation.bpel and interface.wsdl).

On Thu, May 22, 2008 at 8:11 AM, Jean-Jacques Dubray <jd...@gmail.com> wrote:
> Mike:
>
> I don't know if you are talking about this sample:
> https://svn.apache.org/repos/asf/incubator/tuscany/java/sca/samples/helloworld-bpel-ws/
>
> If it's the case, the helloworld.composite does not have a reference, it
> simply exposes a BPEL implementation as a service.
>
> I think I understand a bit better the rationale for not modeling external
> references as "components" and why "components" need to have an
> implementation. I am fine with it since a component must belong to a domain.
>
>
> I have tried to do some cross-domain work by modeling a service (external to
> the domain) invoked by a BPEL implementation and I get some errors. I don't
> know if anyone could help me.
>
> Here is my composite file (I replaced the GreetingsService component by a
> reference to an external web service (implemented in a different domain)):
>
> <?xml version="1.0" encoding="ISO-8859-15"?>
> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0" xmlns:sca="
> http://www.osoa.org/xmlns/sca/1.0" xmlns:hns="http://helloworld"
> xmlns:instance="http://www.w3.org/2004/08/wsdl-instance" xmlns:tuscany="
> http://tuscany.apache.org/xmlns/sca/1.0" name="helloworld" targetNamespace="
> http://bpel">
>  <component name="HelloWorldService">
>    <tuscany:implementation.bpel process="hns:HelloWorld"/>
>    <reference name="greetingsPartnerLink" />
>  </component>
>  <reference name="GreetingsService"
> promote="HelloWorldService/greetingsPartnerLink">
>    <tuscany:interface.wsdl interface="
> http://laptop2:8085/GreetingsService#wsdl.portType(Greetings)"/>
>    <binding.ws wsdlElement="
> http://laptop2:8085/GreetingsService#wsdl.service(GreetingsService)"
> instance:wsdlLocation="http://laptop2:8085/GreetingsService.wsdl"/>
>  </reference>
> </composite>
>
> I do get a series of errors coming from the domain trying to implement this
> composite:
>
> [java] May 22, 2008 7:44:59 AM
> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
> read
>     [java] WARNING: Element {
> http://tuscany.apache.org/xmlns/sca/1.0}implementation.bpel cannot be
> processed. ([row,col {unknown-source}]: [4,5])
>     [java] May 22, 2008 7:44:59 AM
> org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
> read
>     [java] WARNING: Element {
> http://tuscany.apache.org/xmlns/sca/1.0}interface.wsdl cannot be processed.
> ([row,col {unknown-source}]: [8,5])
>     [java] May 22, 2008 7:44:59 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
>     [java] WARNING: No implementation for component: HelloWorldService
>     [java] May 22, 2008 7:44:59 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
>     [java] WARNING: Reference not found for component reference:
> HelloWorldService/greetingsPartnerLink
>     [java] May 22, 2008 7:44:59 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
>     [java] WARNING: No implementation for component: HelloWorldService
>     [java] May 22, 2008 7:44:59 AM
> org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
>     [java] WARNING: Reference not found for component reference:
> HelloWorldService/greetingsPartnerLink
>     [java] No service is declared on component HelloWorldService
>
> BTW, of course the greetings service is up and running and I can query its
> WSDL (v1.1)
>
> In the composite I did try both wsdl.interface and wsdl.portType and got the
> same result (same interface.wsdl cannot be processed)
>
> thanks,
>
> JJ-
>
>
>
>
>
> On Sat, May 17, 2008 at 7:29 AM, Jean-Jacques Dubray <jd...@gmail.com>
> wrote:
>
>> Luciano, Mike:
>>
>> thanks for the detailed answer. Yes, I am aware there are different types.
>> I am not so concerned having to declare an implementation within the same
>> domain. As a matter of fact, it looks to me that it is not even within an
>> entire domain, but within a composite since there is an implementation type
>> which is "implementation.composite", so the scope to which an implementation
>> declaration is exposed is fairly limited (which is good).
>>
>> I am more concerned of "cross domain" interactions and in particular how,
>> say, a .Net based web service gets "assembled". In that case you won't be
>> able to find a valid implementation to expose as a composite. In "cross
>> domain" interactions you are also left to use Web Services technologies
>> (which I'm fine with, it'd be a shame to find no real use for WS-* after all
>> this energy spent :-).
>>
>> Do you have a sample for that use case?
>>
>> thanks,
>>
>> JJ-
>>
>>
>> On Sat, May 17, 2008 at 5:34 AM, Mike Edwards <
>> mike.edwards.inglenook@gmail.com> wrote:
>>
>>> Jean-Jacques Dubray wrote:
>>>
>>>> Luciano:
>>>>
>>>> thanks, actually in the test/bpel/helloworld-reference composite
>>>> definition
>>>> you also have a component defined with a binding.ws and there to, there
>>>> is
>>>> an implementation.java element. Is it required?
>>>>
>>>> <!-- Simple ws-reference -->
>>>>    <!--
>>>>    <component name="HelloWorldService">
>>>>        <implementation.java class="helloworld.HelloWorldServiceImpl"/>
>>>>        <reference name="greetingsService">
>>>>            <binding.ws uri="http://localhost:8085/GreetingsService"/>
>>>>        </reference>
>>>>    </component>
>>>>    -->
>>>>
>>>> Would you consider ws bindings as the preferred way to implement  cross
>>>> domain composites?
>>>>
>>>> JJ-
>>>>
>>>>  Jean-Jacques,
>>>
>>> There may be a misunderstanding going on here....
>>>
>>> Where there is a component in SCA, that says that there is a piece of code
>>> present which implements some function - and that the code provides function
>>> via one or more services and consumes function provided elsewhere through
>>> zero or more references.
>>>
>>> That code is called an implementation - and the implementation can be any
>>> one of many kinds - Java, BPEL, C++, JavaScript, Ruby, etc.  But there must
>>> be an implementation of some kind - and the component declaration is obliged
>>> to point at one.
>>>
>>> In this case, the HelloWorldService component has an implementation that
>>> is a Java POJO - the class
>>> helloworld.HelloWorldServiceImpl.  While this test could have used some
>>> other implementation type such as BPEL, it IS required to have SOME
>>> implementation - otherwise there is no function that the component can
>>> provide.
>>>
>>> The fact that the implementation is a Java POJO does not prevent the
>>> service interface or the reference interface being declared using WSDL and
>>> it also does not prevent the service or reference using a binding that is a
>>> Web service binding also using a WSDL, should that be desirable.
>>>
>>> Here is a simple example of a component implemented by a BPEL process and
>>> exposed as a Web service:
>>>
>>> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
>>>    targetNamespace="http://bpel"
>>>    xmlns:hns="
>>> http://tuscany.apache.org/implementation/bpel/example/helloworld"
>>>    name="bpel">
>>>
>>>    <component name="BPELHelloWorldComponent">
>>>        <implementation.bpel process="hns:HelloWorld"/>
>>>        <service name="helloPartnerLink">
>>>            <interface.wsdl
>>>                 interface="
>>> http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl#
>>>                 wsdl.interface(HelloPortType)" />
>>>            <binding.ws />
>>>        </service>
>>>    </component>
>>>
>>> </composite>
>>>
>>> ....no Java in sight !
>>>
>>> PS - you will find that component in a new BPEL Sample I've recently
>>> committed to the Tuscany SVN - called  "helloworld-bpel-ws".
>>>
>>> Yours,  Mike.
>>>
>>
>>
>>
>> --
>> Jean-Jacques Dubray
>> 425-445-4467
>>
>
>
>
> --
> Jean-Jacques Dubray
> 425-445-4467
>



-- 
Luciano Resende
Apache Tuscany Committer
http://people.apache.org/~lresende
http://lresende.blogspot.com/

Re: Web Service References

Posted by Jean-Jacques Dubray <jd...@gmail.com>.
Mike:

I don't know if you are talking about this sample:
https://svn.apache.org/repos/asf/incubator/tuscany/java/sca/samples/helloworld-bpel-ws/

If it's the case, the helloworld.composite does not have a reference, it
simply exposes a BPEL implementation as a service.

I think I understand a bit better the rationale for not modeling external
references as "components" and why "components" need to have an
implementation. I am fine with it since a component must belong to a domain.


I have tried to do some cross-domain work by modeling a service (external to
the domain) invoked by a BPEL implementation and I get some errors. I don't
know if anyone could help me.

Here is my composite file (I replaced the GreetingsService component by a
reference to an external web service (implemented in a different domain)):

<?xml version="1.0" encoding="ISO-8859-15"?>
<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" xmlns:sca="
http://www.osoa.org/xmlns/sca/1.0" xmlns:hns="http://helloworld"
xmlns:instance="http://www.w3.org/2004/08/wsdl-instance" xmlns:tuscany="
http://tuscany.apache.org/xmlns/sca/1.0" name="helloworld" targetNamespace="
http://bpel">
  <component name="HelloWorldService">
    <tuscany:implementation.bpel process="hns:HelloWorld"/>
    <reference name="greetingsPartnerLink" />
  </component>
  <reference name="GreetingsService"
promote="HelloWorldService/greetingsPartnerLink">
    <tuscany:interface.wsdl interface="
http://laptop2:8085/GreetingsService#wsdl.portType(Greetings)"/>
    <binding.ws wsdlElement="
http://laptop2:8085/GreetingsService#wsdl.service(GreetingsService)"
instance:wsdlLocation="http://laptop2:8085/GreetingsService.wsdl"/>
  </reference>
</composite>

I do get a series of errors coming from the domain trying to implement this
composite:

[java] May 22, 2008 7:44:59 AM
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
     [java] WARNING: Element {
http://tuscany.apache.org/xmlns/sca/1.0}implementation.bpel cannot be
processed. ([row,col {unknown-source}]: [4,5])
     [java] May 22, 2008 7:44:59 AM
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
     [java] WARNING: Element {
http://tuscany.apache.org/xmlns/sca/1.0}interface.wsdl cannot be processed.
([row,col {unknown-source}]: [8,5])
     [java] May 22, 2008 7:44:59 AM
org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
     [java] WARNING: No implementation for component: HelloWorldService
     [java] May 22, 2008 7:44:59 AM
org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
     [java] WARNING: Reference not found for component reference:
HelloWorldService/greetingsPartnerLink
     [java] May 22, 2008 7:44:59 AM
org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
     [java] WARNING: No implementation for component: HelloWorldService
     [java] May 22, 2008 7:44:59 AM
org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
     [java] WARNING: Reference not found for component reference:
HelloWorldService/greetingsPartnerLink
     [java] No service is declared on component HelloWorldService

BTW, of course the greetings service is up and running and I can query its
WSDL (v1.1)

In the composite I did try both wsdl.interface and wsdl.portType and got the
same result (same interface.wsdl cannot be processed)

thanks,

JJ-





On Sat, May 17, 2008 at 7:29 AM, Jean-Jacques Dubray <jd...@gmail.com>
wrote:

> Luciano, Mike:
>
> thanks for the detailed answer. Yes, I am aware there are different types.
> I am not so concerned having to declare an implementation within the same
> domain. As a matter of fact, it looks to me that it is not even within an
> entire domain, but within a composite since there is an implementation type
> which is "implementation.composite", so the scope to which an implementation
> declaration is exposed is fairly limited (which is good).
>
> I am more concerned of "cross domain" interactions and in particular how,
> say, a .Net based web service gets "assembled". In that case you won't be
> able to find a valid implementation to expose as a composite. In "cross
> domain" interactions you are also left to use Web Services technologies
> (which I'm fine with, it'd be a shame to find no real use for WS-* after all
> this energy spent :-).
>
> Do you have a sample for that use case?
>
> thanks,
>
> JJ-
>
>
> On Sat, May 17, 2008 at 5:34 AM, Mike Edwards <
> mike.edwards.inglenook@gmail.com> wrote:
>
>> Jean-Jacques Dubray wrote:
>>
>>> Luciano:
>>>
>>> thanks, actually in the test/bpel/helloworld-reference composite
>>> definition
>>> you also have a component defined with a binding.ws and there to, there
>>> is
>>> an implementation.java element. Is it required?
>>>
>>> <!-- Simple ws-reference -->
>>>    <!--
>>>    <component name="HelloWorldService">
>>>        <implementation.java class="helloworld.HelloWorldServiceImpl"/>
>>>        <reference name="greetingsService">
>>>            <binding.ws uri="http://localhost:8085/GreetingsService"/>
>>>        </reference>
>>>    </component>
>>>    -->
>>>
>>> Would you consider ws bindings as the preferred way to implement  cross
>>> domain composites?
>>>
>>> JJ-
>>>
>>>  Jean-Jacques,
>>
>> There may be a misunderstanding going on here....
>>
>> Where there is a component in SCA, that says that there is a piece of code
>> present which implements some function - and that the code provides function
>> via one or more services and consumes function provided elsewhere through
>> zero or more references.
>>
>> That code is called an implementation - and the implementation can be any
>> one of many kinds - Java, BPEL, C++, JavaScript, Ruby, etc.  But there must
>> be an implementation of some kind - and the component declaration is obliged
>> to point at one.
>>
>> In this case, the HelloWorldService component has an implementation that
>> is a Java POJO - the class
>> helloworld.HelloWorldServiceImpl.  While this test could have used some
>> other implementation type such as BPEL, it IS required to have SOME
>> implementation - otherwise there is no function that the component can
>> provide.
>>
>> The fact that the implementation is a Java POJO does not prevent the
>> service interface or the reference interface being declared using WSDL and
>> it also does not prevent the service or reference using a binding that is a
>> Web service binding also using a WSDL, should that be desirable.
>>
>> Here is a simple example of a component implemented by a BPEL process and
>> exposed as a Web service:
>>
>> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
>>    targetNamespace="http://bpel"
>>    xmlns:hns="
>> http://tuscany.apache.org/implementation/bpel/example/helloworld"
>>    name="bpel">
>>
>>    <component name="BPELHelloWorldComponent">
>>        <implementation.bpel process="hns:HelloWorld"/>
>>        <service name="helloPartnerLink">
>>            <interface.wsdl
>>                 interface="
>> http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl#
>>                 wsdl.interface(HelloPortType)" />
>>            <binding.ws />
>>        </service>
>>    </component>
>>
>> </composite>
>>
>> ....no Java in sight !
>>
>> PS - you will find that component in a new BPEL Sample I've recently
>> committed to the Tuscany SVN - called  "helloworld-bpel-ws".
>>
>> Yours,  Mike.
>>
>
>
>
> --
> Jean-Jacques Dubray
> 425-445-4467
>



-- 
Jean-Jacques Dubray
425-445-4467

Re: Web Service References

Posted by Jean-Jacques Dubray <jd...@gmail.com>.
Luciano, Mike:

thanks for the detailed answer. Yes, I am aware there are different types. I
am not so concerned having to declare an implementation within the same
domain. As a matter of fact, it looks to me that it is not even within an
entire domain, but within a composite since there is an implementation type
which is "implementation.composite", so the scope to which an implementation
declaration is exposed is fairly limited (which is good).

I am more concerned of "cross domain" interactions and in particular how,
say, a .Net based web service gets "assembled". In that case you won't be
able to find a valid implementation to expose as a composite. In "cross
domain" interactions you are also left to use Web Services technologies
(which I'm fine with, it'd be a shame to find no real use for WS-* after all
this energy spent :-).

Do you have a sample for that use case?

thanks,

JJ-

On Sat, May 17, 2008 at 5:34 AM, Mike Edwards <
mike.edwards.inglenook@gmail.com> wrote:

> Jean-Jacques Dubray wrote:
>
>> Luciano:
>>
>> thanks, actually in the test/bpel/helloworld-reference composite
>> definition
>> you also have a component defined with a binding.ws and there to, there
>> is
>> an implementation.java element. Is it required?
>>
>> <!-- Simple ws-reference -->
>>    <!--
>>    <component name="HelloWorldService">
>>        <implementation.java class="helloworld.HelloWorldServiceImpl"/>
>>        <reference name="greetingsService">
>>            <binding.ws uri="http://localhost:8085/GreetingsService"/>
>>        </reference>
>>    </component>
>>    -->
>>
>> Would you consider ws bindings as the preferred way to implement  cross
>> domain composites?
>>
>> JJ-
>>
>>  Jean-Jacques,
>
> There may be a misunderstanding going on here....
>
> Where there is a component in SCA, that says that there is a piece of code
> present which implements some function - and that the code provides function
> via one or more services and consumes function provided elsewhere through
> zero or more references.
>
> That code is called an implementation - and the implementation can be any
> one of many kinds - Java, BPEL, C++, JavaScript, Ruby, etc.  But there must
> be an implementation of some kind - and the component declaration is obliged
> to point at one.
>
> In this case, the HelloWorldService component has an implementation that is
> a Java POJO - the class
> helloworld.HelloWorldServiceImpl.  While this test could have used some
> other implementation type such as BPEL, it IS required to have SOME
> implementation - otherwise there is no function that the component can
> provide.
>
> The fact that the implementation is a Java POJO does not prevent the
> service interface or the reference interface being declared using WSDL and
> it also does not prevent the service or reference using a binding that is a
> Web service binding also using a WSDL, should that be desirable.
>
> Here is a simple example of a component implemented by a BPEL process and
> exposed as a Web service:
>
> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
>    targetNamespace="http://bpel"
>    xmlns:hns="
> http://tuscany.apache.org/implementation/bpel/example/helloworld"
>    name="bpel">
>
>    <component name="BPELHelloWorldComponent">
>        <implementation.bpel process="hns:HelloWorld"/>
>        <service name="helloPartnerLink">
>            <interface.wsdl
>                 interface="
> http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl#
>                 wsdl.interface(HelloPortType)" />
>            <binding.ws />
>        </service>
>    </component>
>
> </composite>
>
> ....no Java in sight !
>
> PS - you will find that component in a new BPEL Sample I've recently
> committed to the Tuscany SVN - called  "helloworld-bpel-ws".
>
> Yours,  Mike.
>



-- 
Jean-Jacques Dubray
425-445-4467

Re: Web Service References

Posted by Mike Edwards <mi...@gmail.com>.
Jean-Jacques Dubray wrote:
> Luciano:
> 
> thanks, actually in the test/bpel/helloworld-reference composite definition
> you also have a component defined with a binding.ws and there to, there is
> an implementation.java element. Is it required?
> 
> <!-- Simple ws-reference -->
>     <!--
>     <component name="HelloWorldService">
>         <implementation.java class="helloworld.HelloWorldServiceImpl"/>
>         <reference name="greetingsService">
>             <binding.ws uri="http://localhost:8085/GreetingsService"/>
>         </reference>
>     </component>
>     -->
> 
> Would you consider ws bindings as the preferred way to implement  cross
> domain composites?
> 
> JJ-
> 
Jean-Jacques,

There may be a misunderstanding going on here....

Where there is a component in SCA, that says that there is a piece of code present which implements 
some function - and that the code provides function via one or more services and consumes function 
provided elsewhere through zero or more references.

That code is called an implementation - and the implementation can be any one of many kinds - Java, 
BPEL, C++, JavaScript, Ruby, etc.  But there must be an implementation of some kind - and the 
component declaration is obliged to point at one.

In this case, the HelloWorldService component has an implementation that is a Java POJO - the class
helloworld.HelloWorldServiceImpl.  While this test could have used some other implementation type 
such as BPEL, it IS required to have SOME implementation - otherwise there is no function that the 
component can provide.

The fact that the implementation is a Java POJO does not prevent the service interface or the 
reference interface being declared using WSDL and it also does not prevent the service or reference 
using a binding that is a Web service binding also using a WSDL, should that be desirable.

Here is a simple example of a component implemented by a BPEL process and exposed as a Web service:

<composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
     targetNamespace="http://bpel"
     xmlns:hns="http://tuscany.apache.org/implementation/bpel/example/helloworld"
     name="bpel">

     <component name="BPELHelloWorldComponent">
         <implementation.bpel process="hns:HelloWorld"/>
         <service name="helloPartnerLink">
             <interface.wsdl
                  interface="http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl#
                  wsdl.interface(HelloPortType)" />
             <binding.ws />
         </service>
     </component>

</composite>

....no Java in sight !

PS - you will find that component in a new BPEL Sample I've recently committed to the Tuscany SVN - 
called  "helloworld-bpel-ws".

Yours,  Mike.

Re: Web Service References

Posted by Jean-Jacques Dubray <jd...@gmail.com>.
Luciano:

thanks, actually in the test/bpel/helloworld-reference composite definition
you also have a component defined with a binding.ws and there to, there is
an implementation.java element. Is it required?

<!-- Simple ws-reference -->
    <!--
    <component name="HelloWorldService">
        <implementation.java class="helloworld.HelloWorldServiceImpl"/>
        <reference name="greetingsService">
            <binding.ws uri="http://localhost:8085/GreetingsService"/>
        </reference>
    </component>
    -->

Would you consider ws bindings as the preferred way to implement  cross
domain composites?

JJ-

On Fri, May 16, 2008 at 12:06 AM, Luciano Resende <lu...@gmail.com>
wrote:

> Hey Jean-Jacques Dubray
>
> Let me try to respond your questions :
>
> The helloworld.composite defined in the
> itest/bpel/helloworld-reference defines a GreetingsServiceComponent
> that is implemented by a simple pojo and has its interface contract
> defined by a wsdl, in this case greetings.wsdl.  This component does
> not use the binding.ws, thus is not exposed as web services.
>
> The helloworld-ws-reference does use the binding.ws to wire to the
> service exposed by the helloworld-ws-service sample.
>
> As for the ws binding, you can use it to consume services available on
> the cloud, you can see this in the demos/xml-bigbank
>
>
> On Thu, May 15, 2008 at 1:07 PM, Jean-Jacques Dubray <jd...@gmail.com>
> wrote:
> > Luciano has pointed me towards a BPEL reference sample. It was
> constructed
> > by using the HelloWord sample which "inovkes" a GreetingsService. The
> > Greeting Service is a regular web service implemented as an SCA composite
> > (similar to the hello-ws sample).
> >
> > The hello world bpel definition exposes itself a service.
> >
> > Even though GreetingsService is a plain vanilla Web Service its reference
> > definition includes an implementation.java element:
> >
> >    <component name="GreetingsServiceComponent">
> >        <implementation.java class="greetings.GreetingsServiceImpl" />
> >
> >        <service name="GreetingsService">
> >            <interface.wsdl interface="
> > http://greetings#wsdl.interface(Greetings)<http://greetings#wsdl.interface%28Greetings%29>"
> />
> >        </service>
> >    </component>
> >
> > this is also true for the helloworld-ws-reference sample:
> >
> >    <reference name="HelloWorldService"
> > promote="HelloWorldServiceComponent/helloWorldService">
> >        <interface.java interface="helloworld.HelloWorldService" />
> >        <binding.ws wsdlElement="
> > http://helloworld#wsdl.port(HelloWorldService/HelloWorldSoapPort)<http://helloworld#wsdl.port%28HelloWorldService/HelloWorldSoapPort%29>
> "/>
> >    </reference>
> >
> > Why is not a WSDL enough?
> >
> > The other question is if you use a WS binding, why does the service has
> to
> > be part of the same domain as the consumers? Could they belong to two
> > different SCA domains? As a matter of fact can a composite consume a WSDL
> > reference that is not part of an SCA domain at all?
> >
> > thanks,
> >
> > --
> > Jean-Jacques Dubray
> > 425-445-4467
> >
>
>
>
> --
> Luciano Resende
> Apache Tuscany Committer
> http://people.apache.org/~lresende <http://people.apache.org/%7Elresende>
> http://lresende.blogspot.com/
>



-- 
Jean-Jacques Dubray
425-445-4467

Re: Web Service References

Posted by Luciano Resende <lu...@gmail.com>.
Hey Jean-Jacques Dubray

Let me try to respond your questions :

The helloworld.composite defined in the
itest/bpel/helloworld-reference defines a GreetingsServiceComponent
that is implemented by a simple pojo and has its interface contract
defined by a wsdl, in this case greetings.wsdl.  This component does
not use the binding.ws, thus is not exposed as web services.

The helloworld-ws-reference does use the binding.ws to wire to the
service exposed by the helloworld-ws-service sample.

As for the ws binding, you can use it to consume services available on
the cloud, you can see this in the demos/xml-bigbank


On Thu, May 15, 2008 at 1:07 PM, Jean-Jacques Dubray <jd...@gmail.com> wrote:
> Luciano has pointed me towards a BPEL reference sample. It was constructed
> by using the HelloWord sample which "inovkes" a GreetingsService. The
> Greeting Service is a regular web service implemented as an SCA composite
> (similar to the hello-ws sample).
>
> The hello world bpel definition exposes itself a service.
>
> Even though GreetingsService is a plain vanilla Web Service its reference
> definition includes an implementation.java element:
>
>    <component name="GreetingsServiceComponent">
>        <implementation.java class="greetings.GreetingsServiceImpl" />
>
>        <service name="GreetingsService">
>            <interface.wsdl interface="
> http://greetings#wsdl.interface(Greetings)" />
>        </service>
>    </component>
>
> this is also true for the helloworld-ws-reference sample:
>
>    <reference name="HelloWorldService"
> promote="HelloWorldServiceComponent/helloWorldService">
>        <interface.java interface="helloworld.HelloWorldService" />
>        <binding.ws wsdlElement="
> http://helloworld#wsdl.port(HelloWorldService/HelloWorldSoapPort)"/>
>    </reference>
>
> Why is not a WSDL enough?
>
> The other question is if you use a WS binding, why does the service has to
> be part of the same domain as the consumers? Could they belong to two
> different SCA domains? As a matter of fact can a composite consume a WSDL
> reference that is not part of an SCA domain at all?
>
> thanks,
>
> --
> Jean-Jacques Dubray
> 425-445-4467
>



-- 
Luciano Resende
Apache Tuscany Committer
http://people.apache.org/~lresende
http://lresende.blogspot.com/