You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Sebastien Arbogast <se...@gmail.com> on 2005/06/09 05:33:45 UTC

[WebServices] How to use the SoapServer component ?

Hi,

I'm looking for a way to use Axis in combination with Cocoon. I
already managed to parse SOAP messages with a higher-level approach
using Axis API's [1] but I still need to automate a few things.

I found a SoapServer interface [2] and a SoapServerImpl [3] class in
Cocoon API documentation, and I found out it was configured in
cocoon.xconf, making it available as an Avalon component but I still
can't figure out how to use it, especially as most of the
implementations I found use XSP and are a bit outdated (as [4] for
example).

I'm not quite sure of the use case I want to implement yet because I
need to know what is possible to achieve with that component first. So
I really could use any sample using that component to serve SOAP
requests through Cocoon. I already sent an e-mail to Marcus Crafter,
the author of that class but as could really use as much experience as
possible because I only have a few days to figure out a solution to
that problem.

I sincerely thank you for any help in advance.
Best regards.
-- 
Sebastien ARBOGAST
[1] http://wiki.apache.org/cocoon/WebServiceServer
[2] http://cocoon.apache.org/2.1/apidocs/org/apache/cocoon/components/axis/SoapServer.html
[3] http://cocoon.apache.org/2.1/apidocs/org/apache/cocoon/components/axis/SoapServerImpl.html
[4] http://webservices.xml.com/pub/a/ws/2003/03/18/cocoon.html

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: [WebServices] How to use the SoapServer component ?

Posted by Vadim Gritsenko <va...@reverycodes.com>.
Sebastien Arbogast wrote:
> So
> I really could use any sample using that component to serve SOAP
> requests through Cocoon.

See samples in the axis block, in the org.apache.cocoon.webservices package and 
under (like System.java).

Vadim

Re: [WebServices] How to use the SoapServer component ?

Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Sebastien Arbogast wrote:

>Hi,
>
>I'm looking for a way to use Axis in combination with Cocoon. I
>already managed to parse SOAP messages with a higher-level approach
>using Axis API's [1] but I still need to automate a few things.
>
>I found a SoapServer interface [2] and a SoapServerImpl [3] class in
>Cocoon API documentation, and I found out it was configured in
>cocoon.xconf, making it available as an Avalon component but I still
>can't figure out how to use it, especially as most of the
>implementations I found use XSP and are a bit outdated (as [4] for
>example).
>
>I'm not quite sure of the use case I want to implement yet because I
>need to know what is possible to achieve with that component first. So
>I really could use any sample using that component to serve SOAP
>requests through Cocoon. I already sent an e-mail to Marcus Crafter,
>the author of that class but as could really use as much experience as
>possible because I only have a few days to figure out a solution to
>that problem.
>
>I sincerely thank you for any help in advance.
>Best regards.
>  
>
I have not used the axis block, but from a short look at it, it seem 
like it mainly embeds Axis as a Cocoon component. So you should probably 
read the Axis users guide to learn the basic concepts 
(http://ws.apache.org/axis/). The actual implementation is in 
o.a.c.components.axis package with a Avalon wrapper in the provider sub 
package. The it is used from the AxisRPCReader. In the o.a.c.webservices 
you have an example of some Avalon based services, that are used from 
the samples. The only use of XSP in the example is for a _client_ that 
calls the SOAP server. But the actual server doesn't use XSP at all. It 
is just the reader and the SOAP server component and the aactual 
services that you implement and descibe in WSDD, and point to in the 
configuration file.

/Daniel


Re: [WebServices] How to use the SoapServer component ?

Posted by Dennis Riedel <de...@web.de>.
Hello Sebastien
Ok. Got your point. Trying to get into this case I asked myself: How can 
I contact the running server through my client?
In the samples/blocks/axis demo I get the status page with the active 
services.

But how do I contact them from my client just to test if it works? It 
seems I don`t find the correct URL.

Regards,
Dennis

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: [WebServices] How to use the SoapServer component ?

Posted by Sebastien Arbogast <se...@gmail.com>.
>  Don`t you just deploy your JWS Files and call them via URL?
>  Axis autogenerates your WSDL when using *.jws Files.
>  
>  Or did I get your problem wrong?

Well... I could do that, I could copy the Axis servlet and configure
my webapp to route *.jws requests to it but the thing is that I don't
want to use Axis alone. I'm trying to combine Axis for connectivity
(my client is mobile so the best solution to connect to the service is
via JSR 172 WSA) with Cocoon for multi-channel capabilities. What I'm
trying to achieve is that I want to intercept the WebService response
at some point to inject it into a few pipelines and then reinsert the
result into a SOAP message before to send it back. You see ?

-- 
Sebastien ARBOGAST

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: [WebServices] How to use the SoapServer component ?

Posted by Dennis Riedel <de...@web.de>.
Don`t you just deploy your JWS Files and call them via URL?
Axis autogenerates your WSDL when using *.jws Files.

Or did I get your problem wrong?

Dennis


Sebastien Arbogast wrote:

>2005/6/8, Geert Josten <Ge...@daidalos.nl>:
>  
>
>>Hi,
>>
>>If that SoapServer is used for [4], than it is actually not a Server but a Client. I am using
>>StreamGenerator to receive SOAP messages and use CIncludeTransformer to translate them to (more or
>>less) internal calls on uri's with request params etc. The result is simply wrapped in a response
>>envelop. Worked okay for me.. ;-)
>>    
>>
>
>I know it's possible. I made it manually too and for one or two
>webservices it would be OK. But one of the main purposes of my
>application is make webservices intergration easier so I don't want to
>write custom things for every service I integrate, all the more so as
>all the information is available for automated processing in WSDL and
>WSDD files. For example I realized that the code in the sample on the
>wiki was wrong, but I realized it only when the client stub generated
>from the WSDL file didn't work because the response message didn't
>match its description.
>So of course I can just find out what's wrong with the response
>message and correct my code but it's just formatting ! I mean for
>every new service I'd have to fine-tune the code manually which is
>very error-prone. And that's precisely why I want to use everything at
>my disposal to focus on what really matters. And SoapServerImpl
>component seems to be a potential answer to my problem, which is why
>I'm looking for examples of use, especially with flowscript instead of
>the "old" XSP...
>
>  
>


Re: [WebServices] How to use the SoapServer component ?

Posted by Sebastien Arbogast <se...@gmail.com>.
2005/6/8, Geert Josten <Ge...@daidalos.nl>:
> Hi,
> 
> If that SoapServer is used for [4], than it is actually not a Server but a Client. I am using
> StreamGenerator to receive SOAP messages and use CIncludeTransformer to translate them to (more or
> less) internal calls on uri's with request params etc. The result is simply wrapped in a response
> envelop. Worked okay for me.. ;-)

I know it's possible. I made it manually too and for one or two
webservices it would be OK. But one of the main purposes of my
application is make webservices intergration easier so I don't want to
write custom things for every service I integrate, all the more so as
all the information is available for automated processing in WSDL and
WSDD files. For example I realized that the code in the sample on the
wiki was wrong, but I realized it only when the client stub generated
from the WSDL file didn't work because the response message didn't
match its description.
So of course I can just find out what's wrong with the response
message and correct my code but it's just formatting ! I mean for
every new service I'd have to fine-tune the code manually which is
very error-prone. And that's precisely why I want to use everything at
my disposal to focus on what really matters. And SoapServerImpl
component seems to be a potential answer to my problem, which is why
I'm looking for examples of use, especially with flowscript instead of
the "old" XSP...

-- 
Sebastien ARBOGAST

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: [WebServices] How to use the SoapServer component ?

Posted by Geert Josten <Ge...@daidalos.nl>.
Hi,

If that SoapServer is used for [4], than it is actually not a Server but a Client. I am using 
StreamGenerator to receive SOAP messages and use CIncludeTransformer to translate them to (more or 
less) internal calls on uri's with request params etc. The result is simply wrapped in a response 
envelop. Worked okay for me.. ;-)

Cheers,
Geert

Sebastien Arbogast wrote:

> Hi,
> 
> I'm looking for a way to use Axis in combination with Cocoon. I
> already managed to parse SOAP messages with a higher-level approach
> using Axis API's [1] but I still need to automate a few things.
> 
> I found a SoapServer interface [2] and a SoapServerImpl [3] class in
> Cocoon API documentation, and I found out it was configured in
> cocoon.xconf, making it available as an Avalon component but I still
> can't figure out how to use it, especially as most of the
> implementations I found use XSP and are a bit outdated (as [4] for
> example).
> 
> I'm not quite sure of the use case I want to implement yet because I
> need to know what is possible to achieve with that component first. So
> I really could use any sample using that component to serve SOAP
> requests through Cocoon. I already sent an e-mail to Marcus Crafter,
> the author of that class but as could really use as much experience as
> possible because I only have a few days to figure out a solution to
> that problem.
> 
> I sincerely thank you for any help in advance.
> Best regards.

-- 
=====================================
NB: het Daidalos kantoor is sinds 22 april
jl. gevestigd op een nieuw adres:

Daidalos BV
Hoekeindsehof 1 - 4
2665 JZ Bleiswijk
tel: +31 (0)10 850 12 00
fax: +31 (0)10 850 11 99

Bovenstaand adres is tevens het postadres.
======================
Geert.Josten@Daidalos.nl
IT-consultant at Daidalos BV

http://www.daidalos.nl/

GPG: 1024D/12DEBB50

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org