[bknr-cvs] edi changed trunk/thirdparty/hunchentoot/

BKNR Commits bknr at bknr.net
Tue Dec 22 22:28:12 UTC 2009


Revision: 4489
Author: edi
URL: http://bknr.net/trac/changeset/4489

Revoke commit 4477

U   trunk/thirdparty/hunchentoot/doc/index.xml
U   trunk/thirdparty/hunchentoot/packages.lisp
U   trunk/thirdparty/hunchentoot/request.lisp

Modified: trunk/thirdparty/hunchentoot/doc/index.xml
===================================================================
--- trunk/thirdparty/hunchentoot/doc/index.xml	2009-12-22 22:14:35 UTC (rev 4488)
+++ trunk/thirdparty/hunchentoot/doc/index.xml	2009-12-22 22:28:12 UTC (rev 4489)
@@ -1594,33 +1594,17 @@
   </clix:returns>
     <clix:description>
 This function is called by <clix:ref>PROCESS-CONNECTION</clix:ref>
-after the incoming headers have been read.  It
-calls <clix:ref>DISPATCH-REQUEST</clix:ref> and sends its output to
-the client.  It also sets up simple error handling for the request
-handler.
-<p>
-The return value of this function is ignored.
-</p>
-    </clix:description>
-  </clix:function>
-
-  <clix:function generic='true' name='dispatch-request'>
-  <clix:lambda-list>request
-  </clix:lambda-list>
-  <clix:returns>nil
-  </clix:returns>
-    <clix:description>
-This function is called by <clix:ref>PROCESS-REQUEST</clix:ref>. It
-selects and calls a
-<a href="#handlers">handler</a> to process the request. 
-<p>
-This might be a good place to introduce around methods which bind
-special variables or do other interesting things that are relevant to
-the particular request. Note
-that <clix:ref>DISPATCH-REQUEST</clix:ref> is called once per
-connection and loops in case of a persistent connection,
+after the incoming headers have been read.  It selects and calls a
+<a href="#handlers">handler</a> and sends the output of this handler
+to the client.  It also sets up simple error handling for the request
+handler.  Note that <clix:ref>PROCESS-CONNECTION</clix:ref> is called
+once per connection and loops in case of a persistent connection
 while <clix:ref>PROCESS-REQUEST</clix:ref> is called anew for each
 request.
+<p>
+Like <clix:ref>PROCESS-CONNECTION</clix:ref>, this might be a good
+place to introduce around methods which bind special variables or do
+other interesting things.
 </p>
 <p>
 The return value of this function is ignored.

Modified: trunk/thirdparty/hunchentoot/packages.lisp
===================================================================
--- trunk/thirdparty/hunchentoot/packages.lisp	2009-12-22 22:14:35 UTC (rev 4488)
+++ trunk/thirdparty/hunchentoot/packages.lisp	2009-12-22 22:28:12 UTC (rev 4489)
@@ -167,7 +167,6 @@
            "DELETE-AUX-REQUEST-VALUE"
            "DELETE-SESSION-VALUE"
            "DISPATCH-EASY-HANDLERS"
-	   "DISPATCH-REQUEST"
            "ESCAPE-FOR-HTML"
            "EXECUTE-ACCEPTOR"
            "GET-PARAMETER"

Modified: trunk/thirdparty/hunchentoot/request.lisp
===================================================================
--- trunk/thirdparty/hunchentoot/request.lisp	2009-12-22 22:14:35 UTC (rev 4488)
+++ trunk/thirdparty/hunchentoot/request.lisp	2009-12-22 22:28:12 UTC (rev 4489)
@@ -95,22 +95,21 @@
 can subclass REQUEST in order to implement your own behaviour.  See
 the REQUEST-CLASS slot of the ACCEPTOR class."))
 
-(defgeneric dispatch-request (request)
-  (:documentation "This function is called by PROCESS-REQUEST. It
-selects and calls a handler to process the request.
-
-This might be a good place to introduce around methods which bind
-special variables or do other interesting things that are relevant to
-the particular request. Note that DISPATCH-REQUEST is called once per
-connection and loops in case of a persistent connection, while
-PROCESS-REQUEST is called anew for each request."))
-  
 (defgeneric process-request (request)
   (:documentation "This function is called by PROCESS-CONNECTION after
-the incoming headers have been read.  It calls DISPATCH-REQUEST and
-sends its output to the client.  It also sets up simple error handling
-for the request handler."))
+the incoming headers have been read.  It selects and calls a handler
+and sends the output of this handler to the client using START-OUTPUT.
+It also sets up simple error handling for the request handler.  Note
+that PROCESS-CONNECTION is called once per connection and loops in
+case of a persistent connection while PROCESS-REQUEST is called anew
+for each request.
 
+Like PROCESS-CONNECTION, this might be a good place to introduce
+around methods which bind special variables or do other interesting
+things.
+
+The return value of this function is ignored."))
+
 (defun convert-hack (string external-format)
   "The rfc2388 package is buggy in that it operates on a character
 stream and thus only accepts encodings which are 8 bit transparent.
@@ -211,12 +210,6 @@
         ;; we assume it's not our fault...
         (setf (return-code*) +http-bad-request+)))))
 
-(defmethod dispatch-request (request)
-  "Standard implementation of dispatching a request to the appropriate
-handler."
-  (funcall (acceptor-request-dispatcher *acceptor*)
-	   request))
-
 (defmethod process-request (request)
   "Standard implementation for processing a request.  You should not
 change or replace this functionality unless you know what you're
@@ -233,7 +226,7 @@
                      ;; skip dispatch if bad request
                      (when (eql (return-code *reply*) +http-ok+)
                        ;; now do the work
-                       (dispatch-request request)))))
+                       (funcall (acceptor-request-dispatcher *acceptor*) *request*)))))
               (when error
                 (setf (return-code *reply*)
                       +http-internal-server-error+))





More information about the Bknr-cvs mailing list