[deprecated] Meddle is a middleware stack for use with HttpServer.jl
9 Stars
Updated Last
2 Years Ago
Started In
April 2013


2015-09-03: This package is deprecated, and does not have an active maintainer. It is not recommended for use in new projects. Commit access may be given to anyone interested in taking on reviving, maintaining, or furthering development. If you are interested, please submit a PR that updates the package. An alternative package is Mux.jl.

Meddle Meddle

Meddle is a middleware stack for use with HttpServer.jl.

Installation: Pkg.add("Meddle")


Define a 'stack' of middleware through which incoming Requests are processed:

using HttpServer
using Meddle

stack = middleware(DefaultHeaders, URLDecoder, CookieDecoder, FileServer(pwd()), NotFound)
http = HttpHandler((req, res)->Meddle.handle(stack, MeddleRequest(req, Dict{Symbol,Any}()), res))

for event in split("connect read write close error")[event] = (event->(client, args...)->println(,": $event"))(event)
end["error"] = (client, err)->println(err)["listen"] = (port)->println("Listening on $port...")

server = Server(http)
run(server, 8000)
::         ::
:: Made at ::
::         ::
Hacker School