異步 HTTP 服務器:Wookie

mmxn 9年前發布 | 9K 次閱讀 Wookie Web服務器

Wookie 是一個用 Common Lisp 編寫的異步 HTTP 服務器,基于 cl-async 和 http-parse 構建。

示例代碼:

(defpackage :wookie-test
  (:use :cl :wookie))
(in-package :wookie-test)

;; load Wookie's core plugins
(load-plugins)

;; define our homepage route
(defroute (:get "/") (req res)
  (send-response res :body "Thanks for stopping by!"))

;; start serving requests!
(as:with-event-loop ()
  (start-server (make-instance 'listener :port 80)))

項目主頁:http://www.baiduhome.net/lib/view/home/1432173279255

 本文由用戶 mmxn 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
 轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
 本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!