You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Miguel Ferreira <mf...@dsi.uminho.pt> on 2007/02/07 12:52:58 UTC
Shared data types between services
Dear all,
How can I share a message definition (i.e. object definition or data
type) between two different web services?
The idea is the following:
I have two distinct web services: service A and service B with web
methods method1 and method2 respectly. Both methods receive a
"Parameter" object type as argument and return the same type.
Summary:
ServiceA
- Paramenter method1(Parameter p);
ServiceB
- Paramenter method2(Parameter p);
I want to build a client that invokes method1 on ServiceA and uses
the response to call method2 on ServiceB. For example:
Parameter a = serviceA.method1(p);
serviceB.method2(a);
The problem is that while building the stubs (using WSDL2Java), I end
up with two different "Parameter" objects, so composition is not
possible.
I can one solve this problem from a SOA perspective using axis.
Thanks in advance.
Best regards,
Miguel
- -
Miguel Ferreira (researcher)
Department of Information Systems
University of Minho Campus de Azurém
4800-058 Guimarães, Portugal
http://www.dsi.uminho.pt/~ferreira/
Phone: +351 253 510 261 / FAX: +351 253 510 300 / Ext.: 510261
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
Re: Shared data types between services
Posted by Alan Birtles <ma...@birtles.org.uk>.
Simply delete one of the generated types and replace all references to
it with the other type.
Quoting Miguel Ferreira <mf...@dsi.uminho.pt>:
>
> Dear all,
>
> How can I share a message definition (i.e. object definition or data
> type) between two different web services?
> The idea is the following:
>
> I have two distinct web services: service A and service B with web
> methods method1 and method2 respectly. Both methods receive a
> "Parameter" object type as argument and return the same type.
>
> Summary:
>
> ServiceA
> - Paramenter method1(Parameter p);
> ServiceB
> - Paramenter method2(Parameter p);
>
> I want to build a client that invokes method1 on ServiceA and uses the
> response to call method2 on ServiceB. For example:
>
> Parameter a = serviceA.method1(p);
> serviceB.method2(a);
>
> The problem is that while building the stubs (using WSDL2Java), I end
> up with two different "Parameter" objects, so composition is not
> possible.
> I can one solve this problem from a SOA perspective using axis.
>
> Thanks in advance.
>
> Best regards,
> Miguel
>
>
> - -
> Miguel Ferreira (researcher)
> Department of Information Systems
> University of Minho Campus de Azurém
> 4800-058 Guimarães, Portugal
> http://www.dsi.uminho.pt/~ferreira/
> Phone: +351 253 510 261 / FAX: +351 253 510 300 / Ext.: 510261
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
Re: Shared data types between services
Posted by Noé Amorim <no...@gmail.com>.
Hello.
This is how do things:
For every web method name, i have 2 types related methodnameRequest
and methodnameResponse.
Even if the "content" is the same, they have diferent names.
With this i think there's no problem doing:
method2Response = serviceB.method2(serviceA.method1(method1_Request)).
On 2/7/07, Miguel Ferreira <mf...@dsi.uminho.pt> wrote:
>
> Dear all,
>
> How can I share a message definition (i.e. object definition or data
> type) between two different web services?
> The idea is the following:
>
> I have two distinct web services: service A and service B with web
> methods method1 and method2 respectly. Both methods receive a
> "Parameter" object type as argument and return the same type.
>
> Summary:
>
> ServiceA
> - Paramenter method1(Parameter p);
> ServiceB
> - Paramenter method2(Parameter p);
>
> I want to build a client that invokes method1 on ServiceA and uses
> the response to call method2 on ServiceB. For example:
>
> Parameter a = serviceA.method1(p);
> serviceB.method2(a);
>
> The problem is that while building the stubs (using WSDL2Java), I end
> up with two different "Parameter" objects, so composition is not
> possible.
> I can one solve this problem from a SOA perspective using axis.
>
> Thanks in advance.
>
> Best regards,
> Miguel
>
>
> - -
> Miguel Ferreira (researcher)
> Department of Information Systems
> University of Minho Campus de Azurém
> 4800-058 Guimarães, Portugal
> http://www.dsi.uminho.pt/~ferreira/
> Phone: +351 253 510 261 / FAX: +351 253 510 300 / Ext.: 510261
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
Re: Shared data types between services
Posted by Jesús Daniel Blázquez Carazo <jd...@gfi-info.com>.
The problem you describe is named "web services interoperability".
I think you should consider the possibility of use a BPEL workflow engine if
you need more interaction between web services.
----- Original Message -----
From: "Miguel Ferreira" <mf...@dsi.uminho.pt>
To: <ax...@ws.apache.org>
Sent: Wednesday, February 07, 2007 12:52 PM
Subject: Shared data types between services
>
> Dear all,
>
> How can I share a message definition (i.e. object definition or data
> type) between two different web services?
> The idea is the following:
>
> I have two distinct web services: service A and service B with web
> methods method1 and method2 respectly. Both methods receive a "Parameter"
> object type as argument and return the same type.
>
> Summary:
>
> ServiceA
> - Paramenter method1(Parameter p);
> ServiceB
> - Paramenter method2(Parameter p);
>
> I want to build a client that invokes method1 on ServiceA and uses the
> response to call method2 on ServiceB. For example:
>
> Parameter a = serviceA.method1(p);
> serviceB.method2(a);
>
> The problem is that while building the stubs (using WSDL2Java), I end up
> with two different "Parameter" objects, so composition is not possible.
> I can one solve this problem from a SOA perspective using axis.
>
> Thanks in advance.
>
> Best regards,
> Miguel
>
>
> - -
> Miguel Ferreira (researcher)
> Department of Information Systems
> University of Minho Campus de Azurém
> 4800-058 Guimarães, Portugal
> http://www.dsi.uminho.pt/~ferreira/
> Phone: +351 253 510 261 / FAX: +351 253 510 300 / Ext.: 510261
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org