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 Pedro Silveira Vieira da Silva <ps...@dcc.online.pt> on 2007/01/08 18:36:35 UTC
What style fits best?
Hi,
Although it might be strange to be asking this after developing an
application with Axis, the truth is that there are some questions still
open.
I've developed an application that makes use of axis for creating a web
service for XML message exchanging. More accurately I have a service
that receives a XML document with some information and makes some
processing with it, rebuilds it and sends it back to the server for some
other job.
For this implementation I've chosen the Message service style, but I've
been wondering why not use the Document style since I'm exchanging
documents? I know that the document style has a return type of void,
which by itself would explain why not use it for message exchanging (at
least I think ...). But since Message style seems to be an axis specific
implementation, is there any other way of doing this, even if it for
compatibility pour purpose?
How was this done before Message style existed?
Thanks in advance,
Pedro Silva
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
Re: What style fits best?
Posted by Anne Thomas Manes <at...@gmail.com>.
As I said:
"It supports any style of message (document/literal, rpc/literal, and
rpc/encoded)."
The WSDD styles "WRAPPED" and "DOCUMENT" produce document/literal messages.
Let me explain by example. Let's say you have a message that looks like this:
<doSomething xmlns="urn:example:wsdd">
<thing1>some string</thing1>
<thing2>another string</thing2>
</doSomething>
If you use "DOCUMENT" style, then Axis will map the doSomething
element and its two children to a bean called "doSomething" with two
attributes of type string.
If you use "WRAPPED" style, then Axis will unwrap the doSomething
element and map the message children (thing1 and thing2) to two string
objects.
Anne
On 1/9/07, Rahul Devgan <rd...@gmail.com> wrote:
> Hi Anne,
> Referring to
> "The "RPC" provider maps XML to Java
> objects. It supports any style of message (document/literal,
> rpc/literal, and rpc/encoded). And depending on your settings, it can
> map the XML message to a single object, or it can automatically
> "unwrap" a message and map the children of the message to beans or
> types."
>
> Does it work with doc/literal as well?
>
>
> On 1/10/07, Anne Thomas Manes <at...@gmail.com> wrote:
> >
> > Pedro,
> >
> > It's important to distinguish between the Axis WSDD "style" and the
> > WSDL "style". The Axis WSDD styles represent a combination of WSDL
> > styles and programming styles.
> >
> > The WSDL styles include document/literal, rpc/literal, and
> > rpc/encoded. These styles represent the way messages are encoded. Note
> > that the WSDL style is orthogonal to the way the application
> > interfaces with the Axis framework.
> >
> > The programming styles represent the way applications interface with
> > the framework. The programming style that you use corresponds to the
> > "provider" that you use to send and receive messages. The "MSG"
> > provider maps XML to DOM. The MSG provider only supports
> > document/literal style messages. The "RPC" provider maps XML to Java
> > objects. It supports any style of message (document/literal,
> > rpc/literal, and rpc/encoded). And depending on your settings, it can
> > map the XML message to a single object, or it can automatically
> > "unwrap" a message and map the children of the message to beans or
> > types.
> >
> > The WSDD styles correspond to providers, programming styles, and WSDL
> > styles this way:
> >
> > Message: MSG provider / map XML messages to DOM / document/literal
> > Document: RPC provider / map XML message to a single value object /
> > document/literal
> > Wrapped: RPC provider / map XML child elements to beans or types /
> > document/literal
> > RPC + use="literal": RPC provider /map XML parameters to beans or
> > types / rpc/literal
> > RPC: RPC provider / map XML parameters to beans or types /rpc/encoded
> >
> > Given that your application works at the XML/DOM level, then you want
> > to stick with "message" style.
> >
> > Anne
> >
> >
> > On 1/8/07, Pedro Silveira Vieira da Silva <ps...@dcc.online.pt> wrote:
> > > Hi,
> > >
> > > Although it might be strange to be asking this after developing an
> > > application with Axis, the truth is that there are some questions still
> > > open.
> > >
> > > I've developed an application that makes use of axis for creating a web
> > > service for XML message exchanging. More accurately I have a service
> > > that receives a XML document with some information and makes some
> > > processing with it, rebuilds it and sends it back to the server for some
> > > other job.
> > >
> > > For this implementation I've chosen the Message service style, but I've
> > > been wondering why not use the Document style since I'm exchanging
> > > documents? I know that the document style has a return type of void,
> > > which by itself would explain why not use it for message exchanging (at
> > > least I think ...). But since Message style seems to be an axis specific
> > > implementation, is there any other way of doing this, even if it for
> > > compatibility pour purpose?
> > >
> > > How was this done before Message style existed?
> > >
> > > Thanks in advance,
> > > Pedro Silva
> > >
> > >
> > >
> ---------------------------------------------------------------------
> > > 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
> >
> >
>
>
>
> --
> warm regards,
> Rahul Devgan
> Cell: +61-412163412
> --- there is no pleasure in life like music ---
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
RE: What style fits best?
Posted by "Yadav, Yogendra (IT)" <Yo...@morganstanley.com>.
Logically, it should, otherwise its a bug.
________________________________
From: Rahul Devgan [mailto:rdevgan@gmail.com]
Sent: Tuesday, January 09, 2007 7:29 PM
To: axis-user@ws.apache.org
Subject: Re: What style fits best?
Hi Anne,
Referring to
"The "RPC" provider maps XML to Java
objects. It supports any style of message (document/literal,
rpc/literal, and rpc/encoded). And depending on your settings, it can
map the XML message to a single object, or it can automatically
"unwrap" a message and map the children of the message to beans or
types."
Does it work with doc/literal as well?
On 1/10/07, Anne Thomas Manes <at...@gmail.com> wrote:
Pedro,
It's important to distinguish between the Axis WSDD "style" and
the
WSDL "style". The Axis WSDD styles represent a combination of
WSDL
styles and programming styles.
The WSDL styles include document/literal, rpc/literal, and
rpc/encoded. These styles represent the way messages are
encoded. Note
that the WSDL style is orthogonal to the way the application
interfaces with the Axis framework.
The programming styles represent the way applications interface
with
the framework. The programming style that you use corresponds to
the
"provider" that you use to send and receive messages. The "MSG"
provider maps XML to DOM. The MSG provider only supports
document/literal style messages. The "RPC" provider maps XML to
Java
objects. It supports any style of message (document/literal,
rpc/literal, and rpc/encoded). And depending on your settings,
it can
map the XML message to a single object, or it can automatically
"unwrap" a message and map the children of the message to beans
or
types.
The WSDD styles correspond to providers, programming styles, and
WSDL
styles this way:
Message: MSG provider / map XML messages to DOM /
document/literal
Document: RPC provider / map XML message to a single value
object /
document/literal
Wrapped: RPC provider / map XML child elements to beans or types
/
document/literal
RPC + use="literal": RPC provider /map XML parameters to beans
or
types / rpc/literal
RPC: RPC provider / map XML parameters to beans or types
/rpc/encoded
Given that your application works at the XML/DOM level, then you
want
to stick with "message" style.
Anne
On 1/8/07, Pedro Silveira Vieira da Silva <ps...@dcc.online.pt>
wrote:
> Hi,
>
> Although it might be strange to be asking this after
developing an
> application with Axis, the truth is that there are some
questions still
> open.
>
> I've developed an application that makes use of axis for
creating a web
> service for XML message exchanging. More accurately I have a
service
> that receives a XML document with some information and makes
some
> processing with it, rebuilds it and sends it back to the
server for some
> other job.
>
> For this implementation I've chosen the Message service style,
but I've
> been wondering why not use the Document style since I'm
exchanging
> documents? I know that the document style has a return type of
void,
> which by itself would explain why not use it for message
exchanging (at
> least I think ...). But since Message style seems to be an
axis specific
> implementation, is there any other way of doing this, even if
it for
> compatibility pour purpose?
>
> How was this done before Message style existed?
>
> Thanks in advance,
> Pedro Silva
>
>
>
---------------------------------------------------------------------
> 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
--
warm regards,
Rahul Devgan
Cell: +61-412163412
--- there is no pleasure in life like music ---
--------------------------------------------------------
NOTICE: If received in error, please destroy and notify sender. Sender does not intend to waive confidentiality or privilege. Use of this email is prohibited when received in error.
Re: What style fits best?
Posted by Rahul Devgan <rd...@gmail.com>.
Hi Anne,
Referring to
"The "RPC" provider maps XML to Java
objects. It supports any style of message (document/literal,
rpc/literal, and rpc/encoded). And depending on your settings, it can
map the XML message to a single object, or it can automatically
"unwrap" a message and map the children of the message to beans or
types."
Does it work with doc/literal as well?
On 1/10/07, Anne Thomas Manes <at...@gmail.com> wrote:
>
> Pedro,
>
> It's important to distinguish between the Axis WSDD "style" and the
> WSDL "style". The Axis WSDD styles represent a combination of WSDL
> styles and programming styles.
>
> The WSDL styles include document/literal, rpc/literal, and
> rpc/encoded. These styles represent the way messages are encoded. Note
> that the WSDL style is orthogonal to the way the application
> interfaces with the Axis framework.
>
> The programming styles represent the way applications interface with
> the framework. The programming style that you use corresponds to the
> "provider" that you use to send and receive messages. The "MSG"
> provider maps XML to DOM. The MSG provider only supports
> document/literal style messages. The "RPC" provider maps XML to Java
> objects. It supports any style of message (document/literal,
> rpc/literal, and rpc/encoded). And depending on your settings, it can
> map the XML message to a single object, or it can automatically
> "unwrap" a message and map the children of the message to beans or
> types.
>
> The WSDD styles correspond to providers, programming styles, and WSDL
> styles this way:
>
> Message: MSG provider / map XML messages to DOM / document/literal
> Document: RPC provider / map XML message to a single value object /
> document/literal
> Wrapped: RPC provider / map XML child elements to beans or types /
> document/literal
> RPC + use="literal": RPC provider /map XML parameters to beans or
> types / rpc/literal
> RPC: RPC provider / map XML parameters to beans or types /rpc/encoded
>
> Given that your application works at the XML/DOM level, then you want
> to stick with "message" style.
>
> Anne
>
>
> On 1/8/07, Pedro Silveira Vieira da Silva <ps...@dcc.online.pt> wrote:
> > Hi,
> >
> > Although it might be strange to be asking this after developing an
> > application with Axis, the truth is that there are some questions still
> > open.
> >
> > I've developed an application that makes use of axis for creating a web
> > service for XML message exchanging. More accurately I have a service
> > that receives a XML document with some information and makes some
> > processing with it, rebuilds it and sends it back to the server for some
> > other job.
> >
> > For this implementation I've chosen the Message service style, but I've
> > been wondering why not use the Document style since I'm exchanging
> > documents? I know that the document style has a return type of void,
> > which by itself would explain why not use it for message exchanging (at
> > least I think ...). But since Message style seems to be an axis specific
> > implementation, is there any other way of doing this, even if it for
> > compatibility pour purpose?
> >
> > How was this done before Message style existed?
> >
> > Thanks in advance,
> > Pedro Silva
> >
> >
> > ---------------------------------------------------------------------
> > 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
>
>
--
warm regards,
Rahul Devgan
Cell: +61-412163412
--- there is no pleasure in life like music ---
Re: What style fits best?
Posted by Pedro Silveira Vieira da Silva <ps...@dcc.online.pt>.
Anne,
Many thanks for your answer. It was very enlightening and the
explanation was the first one in many documents that made it crystal
clear to me.
Hope this thread helps future axis beginner developers.
Thanks,
Pedro
Anne Thomas Manes wrote:
> Pedro,
>
> It's important to distinguish between the Axis WSDD "style" and the
> WSDL "style". The Axis WSDD styles represent a combination of WSDL
> styles and programming styles.
>
> The WSDL styles include document/literal, rpc/literal, and
> rpc/encoded. These styles represent the way messages are encoded. Note
> that the WSDL style is orthogonal to the way the application
> interfaces with the Axis framework.
>
> The programming styles represent the way applications interface with
> the framework. The programming style that you use corresponds to the
> "provider" that you use to send and receive messages. The "MSG"
> provider maps XML to DOM. The MSG provider only supports
> document/literal style messages. The "RPC" provider maps XML to Java
> objects. It supports any style of message (document/literal,
> rpc/literal, and rpc/encoded). And depending on your settings, it can
> map the XML message to a single object, or it can automatically
> "unwrap" a message and map the children of the message to beans or
> types.
>
> The WSDD styles correspond to providers, programming styles, and WSDL
> styles this way:
>
> Message: MSG provider / map XML messages to DOM / document/literal
> Document: RPC provider / map XML message to a single value object /
> document/literal
> Wrapped: RPC provider / map XML child elements to beans or types /
> document/literal
> RPC + use="literal": RPC provider /map XML parameters to beans or
> types / rpc/literal
> RPC: RPC provider / map XML parameters to beans or types /rpc/encoded
>
> Given that your application works at the XML/DOM level, then you want
> to stick with "message" style.
>
> Anne
>
>
> On 1/8/07, Pedro Silveira Vieira da Silva <ps...@dcc.online.pt> wrote:
>> Hi,
>>
>> Although it might be strange to be asking this after developing an
>> application with Axis, the truth is that there are some questions still
>> open.
>>
>> I've developed an application that makes use of axis for creating a web
>> service for XML message exchanging. More accurately I have a service
>> that receives a XML document with some information and makes some
>> processing with it, rebuilds it and sends it back to the server for some
>> other job.
>>
>> For this implementation I've chosen the Message service style, but I've
>> been wondering why not use the Document style since I'm exchanging
>> documents? I know that the document style has a return type of void,
>> which by itself would explain why not use it for message exchanging (at
>> least I think ...). But since Message style seems to be an axis specific
>> implementation, is there any other way of doing this, even if it for
>> compatibility pour purpose?
>>
>> How was this done before Message style existed?
>>
>> Thanks in advance,
>> Pedro Silva
>>
>>
>> ---------------------------------------------------------------------
>> 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
>
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org
Re: What style fits best?
Posted by Anne Thomas Manes <at...@gmail.com>.
Pedro,
It's important to distinguish between the Axis WSDD "style" and the
WSDL "style". The Axis WSDD styles represent a combination of WSDL
styles and programming styles.
The WSDL styles include document/literal, rpc/literal, and
rpc/encoded. These styles represent the way messages are encoded. Note
that the WSDL style is orthogonal to the way the application
interfaces with the Axis framework.
The programming styles represent the way applications interface with
the framework. The programming style that you use corresponds to the
"provider" that you use to send and receive messages. The "MSG"
provider maps XML to DOM. The MSG provider only supports
document/literal style messages. The "RPC" provider maps XML to Java
objects. It supports any style of message (document/literal,
rpc/literal, and rpc/encoded). And depending on your settings, it can
map the XML message to a single object, or it can automatically
"unwrap" a message and map the children of the message to beans or
types.
The WSDD styles correspond to providers, programming styles, and WSDL
styles this way:
Message: MSG provider / map XML messages to DOM / document/literal
Document: RPC provider / map XML message to a single value object /
document/literal
Wrapped: RPC provider / map XML child elements to beans or types /
document/literal
RPC + use="literal": RPC provider /map XML parameters to beans or
types / rpc/literal
RPC: RPC provider / map XML parameters to beans or types /rpc/encoded
Given that your application works at the XML/DOM level, then you want
to stick with "message" style.
Anne
On 1/8/07, Pedro Silveira Vieira da Silva <ps...@dcc.online.pt> wrote:
> Hi,
>
> Although it might be strange to be asking this after developing an
> application with Axis, the truth is that there are some questions still
> open.
>
> I've developed an application that makes use of axis for creating a web
> service for XML message exchanging. More accurately I have a service
> that receives a XML document with some information and makes some
> processing with it, rebuilds it and sends it back to the server for some
> other job.
>
> For this implementation I've chosen the Message service style, but I've
> been wondering why not use the Document style since I'm exchanging
> documents? I know that the document style has a return type of void,
> which by itself would explain why not use it for message exchanging (at
> least I think ...). But since Message style seems to be an axis specific
> implementation, is there any other way of doing this, even if it for
> compatibility pour purpose?
>
> How was this done before Message style existed?
>
> Thanks in advance,
> Pedro Silva
>
>
> ---------------------------------------------------------------------
> 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: What style fits best?
Posted by Rahul Devgan <rd...@gmail.com>.
The following article might help:
http://www-128.ibm.com/developerworks/webservices/library/ws-whichwsdl/
On 1/9/07, Pedro Silveira Vieira da Silva <ps...@dcc.online.pt> wrote:
>
> Hi,
>
> Although it might be strange to be asking this after developing an
> application with Axis, the truth is that there are some questions still
> open.
>
> I've developed an application that makes use of axis for creating a web
> service for XML message exchanging. More accurately I have a service
> that receives a XML document with some information and makes some
> processing with it, rebuilds it and sends it back to the server for some
> other job.
>
> For this implementation I've chosen the Message service style, but I've
> been wondering why not use the Document style since I'm exchanging
> documents? I know that the document style has a return type of void,
> which by itself would explain why not use it for message exchanging (at
> least I think ...). But since Message style seems to be an axis specific
> implementation, is there any other way of doing this, even if it for
> compatibility pour purpose?
>
> How was this done before Message style existed?
>
> Thanks in advance,
> Pedro Silva
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>
--
warm regards,
Rahul Devgan
Cell: +61-412163412
--- there is no pleasure in life like music ---