From d3e3d82683ad2dff8f22b7fe4b0ebf9eb7d25007 Mon Sep 17 00:00:00 2001 From: "Kevin M. Rosenberg" Date: Wed, 20 Aug 2003 01:27:02 +0000 Subject: [PATCH] r5526: *** empty log message *** --- doc/readme.html | 25 +++++++++++++++++- doc/readme.lml | 68 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 91 insertions(+), 2 deletions(-) diff --git a/doc/readme.html b/doc/readme.html index 4da26af..b8fce72 100644 --- a/doc/readme.html +++ b/doc/readme.html @@ -1,4 +1,27 @@ cl-modlisp readme

cl-modlisp Documentation

Overview

cl-modlisp provides the Lisp side of the interface to Marc Battyani's mod_lisp apache module (http://www.fractalconcept.com).

Features

Prerequisites

Supported Platforms

Quickstart

Process Models

There are two process models

Usage

The demo.lisp file for examples of using cl-modlisp.

\ No newline at end of file +mod_lisp, cl-modlisp, and cl-kmrcl manually.
  • Add something like the below to httpd.conf and then restart apache
    LispServer 127.0.0.1 20123 "localhost"
    AddHandler lisp-handler .lsp
  • Start your Lisp implementation and load cl-modlisp with
    (asdf:operate 'asdf:load-op 'modlisp)
  • Start the server with
    (ml:modlisp-start :port 20123)
  • Try some demostration pages
    links http://localhost/fixed.lsp
    links http://localhost/debug.lsp
  • Shutdown the all cl-modlisp servers with
    (ml:modlisp-stop-all)
  • Process Models

    There are two process models

    Usage

    The demo.lisp file for examples of using cl-modlisp.

  • Overview
    cl-modlisp is a multi-threaded handler for HTTP requests forwarded by Marc Battyani's (http://www.fractalconcept.com) mod_lisp Apache module.
  • Design Goals
    cl-modlisp is designed as a thin layer to dispatch a mod_lisp request with multi-platform compatibility. Currently, cl-modlisp supports SBCL [multithreaded], CMUCL, AllegroCL, and Lispworks.
  • Dispatch model
    Extremely simple: All requests are forwarded to a single processor that is passed as a parameter to cl-modlisp's start-up function.
  • Configuration
    All configuration is set by passing keyword arguments to +modlisp-start
  • Processor function
    This function receives an argument of the 'command' alist and any +other arguments passed to modlisp-start as the :processor-args. The +'command' alist is an associative list of keys and values received +from modlisp. No preprocessing is done except that keys are converted +from strings to keywords forced to the default implementation case.
  • Default Processor
    The default processor is a simple demo command processor not intended for end-user.
  • URI Processing
    None. The raw URL is the value of the :url key in the command alist.
  • Responses
    Responses are written to modlisp:*modlisp-socket*. The raw HTTP/1.1 header needs to be generated by the application.
  • Utility functions
    A few utility functions are provided
  • Known issues
  • \ No newline at end of file diff --git a/doc/readme.lml b/doc/readme.lml index 5ebbb05..fcb4b39 100644 --- a/doc/readme.lml +++ b/doc/readme.lml @@ -91,9 +91,75 @@ mod_lisp, cl-modlisp, and cl-kmrcl manually.")) (:h2 "Usage") (:p "The demo.lisp file for examples of using cl-modlisp.") - ))) + ) + (:ul) + (:li (:div (:strong "Overview")) + (:div "cl-modlisp is a multi-threaded handler for HTTP requests forwarded by Marc Battyani's (http://www.fractalconcept.com) mod_lisp Apache module.")) + (:li (:div (:strong "Design Goals")) + (:div "cl-modlisp is designed as a thin layer to dispatch a mod_lisp request with multi-platform compatibility. Currently, cl-modlisp supports SBCL [multithreaded], CMUCL, AllegroCL, and Lispworks.")) + (:li (:div (:strong "Dispatch model")) + (:div "Extremely simple: All requests are forwarded to a single processor that is passed as a parameter to cl-modlisp's start-up function.")) + (:li (:div (:strong "Configuration")) + (:div "All configuration is set by passing keyword arguments to +modlisp-start") + (:ul + (:li "port number - a number") + (:li "processor - function designator which will receive all requests") + (:li "processor-args - list of extra arguments to be passed to processor") + (:li "timeout - NIL means never timeout otherwise number of seconds") + (:li "catch-errors - non-NIL means to catch errors") + (:li "number-fixed-workers - NIL means to spawn a new worker process for each request") + (:li "remote-host-checker - optional function designator to check the remote host IP address. Used for filtering requests."))) + (:li (:div (:strong "Processor function")) + (:div +"This function receives an argument of the 'command' alist and any +other arguments passed to modlisp-start as the :processor-args. The +'command' alist is an associative list of keys and values received +from modlisp. No preprocessing is done except that keys are converted +from strings to keywords forced to the default implementation case.")) + (:li (:div (:strong "Default Processor")) + (:div "The default processor is a simple demo command processor not intended for end-user.")) + (:li (:div "URI Processing") + (:div "None. The raw URL is the value of the :url key in the command alist.")) + (:li (:div "Responses") + (:div "Responses are written to modlisp:*modlisp-socket*. The raw HTTP/1.1 header needs to be generated by the application.")) + (:li (:div "Utility functions") + (:div "A few utility functions are provided") + (:ul + (:li (:div "with-ml-page") + (:div "Outputs the body of the macro along with the HTTP/1.1 headers. Supports both precomputing responses with keep-alive connections and also outputing response to socket as it is generated. The latter is useful for lengthye reponses in time or length. Also support setting the content-type (default \"text/html\") and arbitrary list of headers.")) + (:li (:div "query-to-alist") + (:div "Converts posted query to an alist. Doesn't handle multipart forms.")) + (:li (:div "redirect-to-location")))) + (:li (:div (:strong "Known issues")) + (:ul + (:li "This application has been most tested on AllegroCL.") + (:li +(:p "By design, is not practical an application platform. It is should have +an API package wrapped around this library which supports useful +features like processing URIs, dispatches, cookies, and querys [URI +and single/multipart POSTs]") +(:p +"Rather than adding these features to cl-modlisp, I've been working on +a library which uses a session-id and dispatch model based on Franz's +webactions library. It also integrates my portable version of Franz's +URI module and adds query processing similar on AllegroServer's +request-query functions. This library can used with both cl-modlisp +and AllegroServe as connectors. However, as this library has grown, it +looks more and more like AllegroServe, I've begun to question the +value of using this library compared to just using Portable +AllegroServe with just my webactions-like session-id and dispatch +processors. In my mind, the greatest advantage of using this library +is that it is a much smaller task maintaining cross-implementation +compatibility with the cl-modlisp connector version maintaining such +compatibility with paserve. The disadvantage of this library is that I +dislike cloning AllegroServe's query and cookie processing. I do so, +though, because I think their API is quite reasonable. This library +is currently driving http://umlisp.b9.com/") +))))) + -- 2.34.1