[Q] Adding SOAP as module of KomHttpService(like Seaside)

Masashi UMEZAWA masashi.umezawa at gmail.com
Tue Jun 19 00:05:22 UTC 2007


Hi Sungjin,

In the code example, "komRequest url = '/soap'" should be "komRequest
url beginsWith: '/soap'" for handling various SOAP requests (of
course).

And personally I prefer using content type ('text/xml') for
dispatching SOAP. It is good because you can use different URLs
freely.

process: komRequest
  prop := komRequest propertyAt: #contentType ifAbsent: [].
  prop = MIMEDocument contentTypeXml
	ifTrue: [^ self soapModule process: komRequest].
  ^super process: komRequest

Cheers,

2007/6/18, Masashi UMEZAWA <masashi.umezawa at gmail.com>:
> Hi Sungjin,
>
> A simple solution is to make a subclass of WAKom and override
> #process: for  dispatching like:
>
> process: komRequest
>         komRequest url = '/soap' ifTrue:[ ^ self soapModule process: komRequest].
>         ^ super process: komRequest
>
> soapModule
>         soapModule ifNil: [soapModule := SoapHttpModule new].
>         ^soapModule
>
> Cheers,
>
> 2007/6/18, Sungjin Chun <chunsj at embian.com>:
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > Hi,
> >
> > How can I add soap processing module to KomHttpService as Seaside so
> > that I can assign "/soap" as url for soap. For example Seaside
> > uses "/seaside" for its service url for KomHttpService. What I want to
> > do is use same port number for seaside and soap, only url be different.
> >
> > Sorry for my poor English and Thanks in advance.
> > -----BEGIN PGP SIGNATURE-----
> > Version: GnuPG v1.4.2.2 (GNU/Linux)
> > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
> >
> > iD8DBQFGdfFiQqspS1+XJHgRAgVfAKCdPVOOniDHS/R9scE6Bbg+85YpSwCeJcUL
> > b4R37ckhk7NHV2RZc8ZR/is=
> > =0U51
> > -----END PGP SIGNATURE-----
> >
> --
> [:masashi | ^umezawa]

-- 
[:masashi | ^umezawa]



More information about the Squeak-dev mailing list