You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by C Santosh Kumar <cs...@ebizportals.com> on 2001/10/15 10:24:06 UTC

Re: Doubt on Web Services -SOAP

.
>
>  I want to know whether I've to send the whole XML request in the SOAP
>  request and same in the case of XML response also.Generally we'll format
a
>  SOAP request with the service to be called and with the required
> parameters.
>  But here I want to send the whole XML request/response as a SOAP
> request/response.
>  Is there any way to do that.


The first one is rpc-style and the second one(the one which u want)
is document style. In the document style, you can send plain xml
inside the body of the soap envelope.
If you are using Apache soap-2.2, read about writing message server/clients
in the documentation there.

santosh.


RE: Send SOAPMessage from EJB

Posted by "T. Carson Hager" <ca...@cynergysystems.com>.
What's the exception?  What EJB container are you using?

As a note, there's nothing in the EJB spec restricting POST requests from a
bean of any type.  There's nothing even related to that at all.  The only
thing close is the use of file I/O but that's a whole different set of
packages.


Carson

__________________________________________________________

Carson Hager
Cynergy Systems, Inc.
Sybase Enterprise Application Studio Consulting and Training
http://www.cynergysystems.com



> -----Original Message-----
> From: Lam Ngoc Le [mailto:lamln@cocovn.com]
> Sent: Wednesday, October 17, 2001 4:14 AM
> To: soap-user@xml.apache.org
> Subject: Send SOAPMessage from EJB
>
>
> I tried to send SOAPMessage from a EJB by using JAXM, so I
> have exceptions.
> The problem may EJB container do not allow POST message from
> container out.
> Any help is appreciated!!!
> Thank alot,
> Lam
>
>
>


RE: Send SOAPMessage from EJB

Posted by "T. Carson Hager" <ca...@cynergysystems.com>.
What's the exception?  What EJB container are you using?

As a note, there's nothing in the EJB spec restricting POST requests from a
bean of any type.  There's nothing even related to that at all.  The only
thing close is the use of file I/O but that's a whole different set of
packages.


Carson

__________________________________________________________

Carson Hager
Cynergy Systems, Inc.
Sybase Enterprise Application Studio Consulting and Training
http://www.cynergysystems.com



> -----Original Message-----
> From: Lam Ngoc Le [mailto:lamln@cocovn.com]
> Sent: Wednesday, October 17, 2001 4:14 AM
> To: soap-user@xml.apache.org
> Subject: Send SOAPMessage from EJB
>
>
> I tried to send SOAPMessage from a EJB by using JAXM, so I
> have exceptions.
> The problem may EJB container do not allow POST message from
> container out.
> Any help is appreciated!!!
> Thank alot,
> Lam
>
>
>


Send SOAPMessage from EJB

Posted by Lam Ngoc Le <la...@cocovn.com>.
I tried to send SOAPMessage from a EJB by using JAXM, so I have exceptions.
The problem may EJB container do not allow POST message from container out.
Any help is appreciated!!!
Thank alot,
Lam



Send SOAPMessage from EJB

Posted by Lam Ngoc Le <la...@cocovn.com>.
I tried to send SOAPMessage from a EJB by using JAXM, so I have exceptions.
The problem may EJB container do not allow POST message from container out.
Any help is appreciated!!!
Thank alot,
Lam



Re: Doubt on Web Services -SOAP

Posted by C Santosh Kumar <cs...@ebizportals.com>.
----- Original Message -----
From: "David Wall" <dw...@Yozons.com>
To: "C Santosh Kumar" <cs...@ebizportals.com>
Sent: Wednesday, October 17, 2001 10:25 AM
Subject: Re: Doubt on Web Services -SOAP


> > > Maybe I don't understand, but why can't he just use a standard SOAP
RPC
> > > request and return a String that contains the XML response?
> > >
> >
> >
> > With proper encoding, I guess this can be done. But it is not
recomended.
> > document style is for those systems which take XML and give out XML.
> > and rpc style is for those which take data in the form of some "simple"
> > parameters
> > and give out similar output(a typical procedure does this).
> >
> > So depending on how you modelled your service, you can choose one of the
> > above.
>
> Well, I don't use simple parameters at all, but I'm using the
BeanSerializer
> for my complex objects, many of which contain arrays of other complex
> objects.  Most of my methods are standard RPC (heck, I'm not even sure
> how/why I'd change the style and what it would mean for my code).  But one
> returns a String that is an XML document.  It's not that this is trying to
> get around anything, but our software produces some responses in XML for
> offline storage, and when that is called via SOAP, it also returns the
data
> in XML.  It seems to work without any problem, so I hope there's nothing
> "wrong" with this approach.  From what I gather, all String parameters
> should be properly encoded by the SOAP layer automatically.
>
> David
>
>



yes, you are not wrong. it is a matter of choice. If you already have
your setup up and running, then it is okay. But if you have to start from
ground up, then you might want to consider the document style also.
Ofcourse, in the document style, there is this problem of client knowing
the structure of your xml and it is a different issue altogether.

Santosh

PS: sending this to mailing list for benifit of other readers.
and comments ofcourse:-)



Re: Doubt on Web Services -SOAP

Posted by C Santosh Kumar <cs...@ebizportals.com>.
----- Original Message -----
From: "David Wall" <dw...@Yozons.com>
To: "C Santosh Kumar" <cs...@ebizportals.com>
Sent: Wednesday, October 17, 2001 10:25 AM
Subject: Re: Doubt on Web Services -SOAP


> > > Maybe I don't understand, but why can't he just use a standard SOAP
RPC
> > > request and return a String that contains the XML response?
> > >
> >
> >
> > With proper encoding, I guess this can be done. But it is not
recomended.
> > document style is for those systems which take XML and give out XML.
> > and rpc style is for those which take data in the form of some "simple"
> > parameters
> > and give out similar output(a typical procedure does this).
> >
> > So depending on how you modelled your service, you can choose one of the
> > above.
>
> Well, I don't use simple parameters at all, but I'm using the
BeanSerializer
> for my complex objects, many of which contain arrays of other complex
> objects.  Most of my methods are standard RPC (heck, I'm not even sure
> how/why I'd change the style and what it would mean for my code).  But one
> returns a String that is an XML document.  It's not that this is trying to
> get around anything, but our software produces some responses in XML for
> offline storage, and when that is called via SOAP, it also returns the
data
> in XML.  It seems to work without any problem, so I hope there's nothing
> "wrong" with this approach.  From what I gather, all String parameters
> should be properly encoded by the SOAP layer automatically.
>
> David
>
>



yes, you are not wrong. it is a matter of choice. If you already have
your setup up and running, then it is okay. But if you have to start from
ground up, then you might want to consider the document style also.
Ofcourse, in the document style, there is this problem of client knowing
the structure of your xml and it is a different issue altogether.

Santosh

PS: sending this to mailing list for benifit of other readers.
and comments ofcourse:-)



Re: Doubt on Web Services -SOAP

Posted by C Santosh Kumar <cs...@ebizportals.com>.
----- Original Message -----
From: "David Wall" <dw...@Yozons.com>
To: <so...@xml.apache.org>
Sent: Tuesday, October 16, 2001 9:19 PM
Subject: Re: Doubt on Web Services -SOAP


> > > The first one is rpc-style and the second one(the one which u want)
> > > is document style. In the document style, you can send plain xml
> > > inside the body of the soap envelope.
> > > If you are using Apache soap-2.2, read about writing message
> server/clients
> > > in the documentation there.
>
> Maybe I don't understand, but why can't he just use a standard SOAP RPC
> request and return a String that contains the XML response?
>


With proper encoding, I guess this can be done. But it is not recomended.
document style is for those systems which take XML and give out XML.
and rpc style is for those which take data in the form of some "simple"
parameters
and give out similar output(a typical procedure does this).

So depending on how you modelled your service, you can choose one of the
above.


Re: Doubt on Web Services -SOAP

Posted by C Santosh Kumar <cs...@ebizportals.com>.
----- Original Message -----
From: "David Wall" <dw...@Yozons.com>
To: <so...@xml.apache.org>
Sent: Tuesday, October 16, 2001 9:19 PM
Subject: Re: Doubt on Web Services -SOAP


> > > The first one is rpc-style and the second one(the one which u want)
> > > is document style. In the document style, you can send plain xml
> > > inside the body of the soap envelope.
> > > If you are using Apache soap-2.2, read about writing message
> server/clients
> > > in the documentation there.
>
> Maybe I don't understand, but why can't he just use a standard SOAP RPC
> request and return a String that contains the XML response?
>


With proper encoding, I guess this can be done. But it is not recomended.
document style is for those systems which take XML and give out XML.
and rpc style is for those which take data in the form of some "simple"
parameters
and give out similar output(a typical procedure does this).

So depending on how you modelled your service, you can choose one of the
above.


Re: Doubt on Web Services -SOAP

Posted by David Wall <dw...@Yozons.com>.
> > The first one is rpc-style and the second one(the one which u want)
> > is document style. In the document style, you can send plain xml
> > inside the body of the soap envelope.
> > If you are using Apache soap-2.2, read about writing message
server/clients
> > in the documentation there.

Maybe I don't understand, but why can't he just use a standard SOAP RPC
request and return a String that contains the XML response?

David


Re: Doubt on Web Services -SOAP

Posted by David Wall <dw...@Yozons.com>.
> > The first one is rpc-style and the second one(the one which u want)
> > is document style. In the document style, you can send plain xml
> > inside the body of the soap envelope.
> > If you are using Apache soap-2.2, read about writing message
server/clients
> > in the documentation there.

Maybe I don't understand, but why can't he just use a standard SOAP RPC
request and return a String that contains the XML response?

David


Re: Doubt on Web Services -SOAP

Posted by PITCHUKA SRINIVASA RAO <ps...@cmcltd.com>.
Thank you Santosh.I'll get back to you after reading the Doc.

Thanks and regards,
Sreenivas

On Mon, 15 Oct 2001, C Santosh Kumar wrote:

> .
> >
> >  I want to know whether I've to send the whole XML request in the SOAP
> >  request and same in the case of XML response also.Generally we'll format
> a
> >  SOAP request with the service to be called and with the required
> > parameters.
> >  But here I want to send the whole XML request/response as a SOAP
> > request/response.
> >  Is there any way to do that.
> 
> 
> The first one is rpc-style and the second one(the one which u want)
> is document style. In the document style, you can send plain xml
> inside the body of the soap envelope.
> If you are using Apache soap-2.2, read about writing message server/clients
> in the documentation there.
> 
> santosh.
> 


Re: Doubt on Web Services -SOAP

Posted by PITCHUKA SRINIVASA RAO <ps...@cmcltd.com>.
Thank you Santosh.I'll get back to you after reading the Doc.

Thanks and regards,
Sreenivas

On Mon, 15 Oct 2001, C Santosh Kumar wrote:

> .
> >
> >  I want to know whether I've to send the whole XML request in the SOAP
> >  request and same in the case of XML response also.Generally we'll format
> a
> >  SOAP request with the service to be called and with the required
> > parameters.
> >  But here I want to send the whole XML request/response as a SOAP
> > request/response.
> >  Is there any way to do that.
> 
> 
> The first one is rpc-style and the second one(the one which u want)
> is document style. In the document style, you can send plain xml
> inside the body of the soap envelope.
> If you are using Apache soap-2.2, read about writing message server/clients
> in the documentation there.
> 
> santosh.
>