[Seaside] HTTP Server Structure
Sven Van Caekenberghe
sven at beta9.be
Wed Nov 19 15:10:24 CET 2003
On 18 Nov 2003, at 00:20, Nevin Pratt wrote:
> Sven Van Caekenberghe wrote:
>> No, my question was, why make a subclass of WAKom instead of a
>> module/plug/whatever directly in Comanche ?
>
To answer my own question: I now have Seaside, static file serving and
XML-RPC in one image, under the same port using this code:
| ma xmlrpc seaside |
ma := ModuleAssembly core.
ma serverRoot: (FileDirectory on: '/Users/sven/Sites/') fullName.
xmlrpc := XMLRPCHttpModule new.
ma alias: '/xmlrpc' to: [ma addPlug: [:request | xmlrpc process:
request]].
seaside := WAKom default.
ma alias: '/seaside' to: [ma addPlug: [:request | seaside process:
request]].
ma documentRoot: (FileDirectory on: '/Users/sven/Sites/') fullName.
ma directoryIndex: 'index.html index.htm'.
ma serveFiles.
(HttpService startOn: 9090 named: 'httpd') plug: ma rootModule
This is very elegant, I like begin to like the heavily refactored
design that was confusing at first.
Sven
More information about the Seaside
mailing list