This mail was originally from Michael Homeijer

---------- Forwarded message ----------
Date: Wed, 30 May 2001 14:33:29 +0000 (GMT)
From: Alex Dijk <[EMAIL PROTECTED]>
To: giacomo <[EMAIL PROTECTED]>
Subject: Re: SOAP client and server  - Scanned for virus

Giacomo wrote:
>
> On Fri, 25 May 2001, Michael Homeijer wrote:
>
> > Hi,
> >
> > I am developing a SOAP prototype for Cocoon and need some feedback on my
> > first results.
> > The setup consists of a logic sheet, an xsp page with a SOAP request and an
> > xsp page with a SOAP response.
>
> If I understand that correctly you are mentioning "a xsp page with SOAP
> request" for C2 act as a SOAP client and with "a xsp page with SOAP
> response" act as SOAP server, right? Is the logicsheet covering both
> aspects?

That's right, but until now I only worked out the request part. The service\dynamic.xml
xsp page shows what has to be done to create a SOAP service.
>
> > Both the request and the response work on the basis of soap envelopes.
> > The sample uses the "Weather - Temperature" service (id=8) from xmethods.
> >
> > I'd appreciate comment/feedback or some help on the todo topics.
> >
> > To install the sample:
> > - put the apache soap jar from http://xml.apache.org/soap/index.html in your
> > classpath
> > - upgrade xerces to version 1.4.0 (1.3.1 does not work with soap while 1.2.1
> > does and 1.2.1 does not work with cocoon 2)
> > - put the soaplib.jar with the logicsheet in your classpath
> > - put the following reference to the logicsheet in cocoon.xconf
> >         <builtin-logicsheet>
> >           <parameter name="prefix" value="soap"/>
> >           <parameter name="uri" value="http://soaplib"/>
> >           <parameter name="href" value="resource://soap-lib.xsl"/>
> >         </builtin-logicsheet>
>
> Do you intend to "donate" your code to the C2 base and can we change the
> package and URI space names to Apache Cocoon 2 standards?

For me, the code will be used to design a service layer in our company framework based 
on cocoon. If you "adopt" the code, I'll be happy to use it and maybe develop some new 
ideas...
So go ahead and use it. BTW: This first version was to get some feedback on how SOAP 
should really be integrated with Cocoon so I don't mind anyone offending my solution 
as long as we get something working ;-)

>
> > - put the following lines in sitemap.xmap
> >    <map:match pattern="soaplib/*.xsp">
> >       <map:generate type="serverpages" src="htdocs/soaplib/{1}.xml"/>
> >       <map:transform src="htdocs/soaplib/{1}.xsl"/>
> >       <map:serialize/>
> >    </map:match>
> >
> >    <map:match pattern="soaplib/service/*.xsp">
> >       <map:generate type="serverpages"
> > src="htdocs/soaplib/service/{1}.xml"/>
> >       <map:serialize type="xml"/>
> >    </map:match>
> > - put the sample from soaplib.zip in htdocs/soaplib in the c2 root directory
> > - retrieve http://localhost/c2/soaplib/temp.xsp in your browser
> >
> > The following stuff is on my todo list for the SOAP client request:
> > - Add the normal xsp parameter handling templates to the logic sheet
> > - Convert java variables from xsp into soap parameters
> > - Output the SOAP response envelope in xml to the server page
> >
> > As far as I understand Cocoon 2 components, I plan to implement the
> > following for the SOAP service:
> > - Create an action that extracts and validates the soap request envelope
> > from the httpservletrequest (code to use from apache soap is
> > service\dynamic1.xml)
>
> Sort of.

I'd love some documentation and clear examples on these Cocoon techniques. Until now 
I've learnt the most from building with Cocoon and I don't quite know where to start 
with this new stuff.

>
> > - Create a selector that is able to select a server page based on the method
> > in the soap request envelope
>
> What do you think of implementing the services as Avalon Components and
> have a more generic xsp page/generator to map those Avalon Component
> into a SOAP response (not that I'm offending your solution :) ?
>

I'm listening.... if you could be more specific, I'll try to setup something. ;-)

> > - Create a soap:response tag in the logic sheet
> > - Create tags to map java variables to soap tags
>
> Can we postpone the integration of this code into the repository after
> we've made the beta 1 (I propose it will go into the 2.1 release)
>

Yes ok.

> Many thanks
>
> Giacomo

Can't wait for the beta

Thanks,
Michael

Giacomo wrote:
> 
> On Fri, 25 May 2001, Michael Homeijer wrote: 
> 
> > Hi, 
> > 
> > I am developing a SOAP prototype for Cocoon and need some feedback on my 
> > first results. 
> > The setup consists of a logic sheet, an xsp page with a SOAP request and an 
> > xsp page with a SOAP response. 
> 
> If I understand that correctly you are mentioning "a xsp page with SOAP 
> request" for C2 act as a SOAP client and with "a xsp page with SOAP 
> response" act as SOAP server, right? Is the logicsheet covering both 
> aspects? 

That's right, but until now I only worked out the request part. The 
service\dynamic.xml 
xsp page shows what has to be done to create a SOAP service.
> 
> > Both the request and the response work on the basis of soap envelopes. 
> > The sample uses the "Weather - Temperature" service (id=8) from xmethods. 
> > 
> > I'd appreciate comment/feedback or some help on the todo topics. 
> > 
> > To install the sample: 
> > - put the apache soap jar from http://xml.apache.org/soap/index.html in your 
> > classpath 
> > - upgrade xerces to version 1.4.0 (1.3.1 does not work with soap while 1.2.1 
> > does and 1.2.1 does not work with cocoon 2) 
> > - put the soaplib.jar with the logicsheet in your classpath 
> > - put the following reference to the logicsheet in cocoon.xconf 
> >         <builtin-logicsheet> 
> >           <parameter name="prefix" value="soap"/> 
> >           <parameter name="uri" value="http://soaplib"/> 
> >           <parameter name="href" value="resource://soap-lib.xsl"/> 
> >         </builtin-logicsheet> 
> 
> Do you intend to "donate" your code to the C2 base and can we change the 
> package and URI space names to Apache Cocoon 2 standards? 

For me, the code will be used to design a service layer in our company framework based 
on cocoon. If you "adopt" the code, I'll be happy to use it and maybe develop some new 
ideas...
So go ahead and use it. BTW: This first version was to get some feedback on how SOAP 
should really be integrated with Cocoon so I don't mind anyone offending my solution 
as long as we get something working ;-)

> 
> > - put the following lines in sitemap.xmap 
> >    <map:match pattern="soaplib/*.xsp"> 
> >       <map:generate type="serverpages" src="htdocs/soaplib/{1}.xml"/> 
> >       <map:transform src="htdocs/soaplib/{1}.xsl"/> 
> >       <map:serialize/> 
> >    </map:match> 
> > 
> >    <map:match pattern="soaplib/service/*.xsp"> 
> >       <map:generate type="serverpages" 
> > src="htdocs/soaplib/service/{1}.xml"/> 
> >       <map:serialize type="xml"/> 
> >    </map:match> 
> > - put the sample from soaplib.zip in htdocs/soaplib in the c2 root directory 
> > - retrieve http://localhost/c2/soaplib/temp.xsp in your browser 
> > 
> > The following stuff is on my todo list for the SOAP client request: 
> > - Add the normal xsp parameter handling templates to the logic sheet 
> > - Convert java variables from xsp into soap parameters 
> > - Output the SOAP response envelope in xml to the server page 
> > 
> > As far as I understand Cocoon 2 components, I plan to implement the 
> > following for the SOAP service: 
> > - Create an action that extracts and validates the soap request envelope 
> > from the httpservletrequest (code to use from apache soap is 
> > service\dynamic1.xml) 
> 
> Sort of. 

I'd love some documentation and clear examples on these Cocoon techniques. Until now 
I've learnt the most from building with Cocoon and I don't quite know where to start 
with this new stuff.

> 
> > - Create a selector that is able to select a server page based on the method 
> > in the soap request envelope 
> 
> What do you think of implementing the services as Avalon Components and 
> have a more generic xsp page/generator to map those Avalon Component 
> into a SOAP response (not that I'm offending your solution :) ? 
> 

I'm listening.... if you could be more specific, I'll try to setup something. ;-)

> > - Create a soap:response tag in the logic sheet 
> > - Create tags to map java variables to soap tags 
> 
> Can we postpone the integration of this code into the repository after 
> we've made the beta 1 (I propose it will go into the 2.1 release) 
> 

Yes ok.

> Many thanks 
> 
> Giacomo 

Can't wait for the beta 

Thanks,
Michael
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to