package rock

  1. Overview
  2. Docs
Minimalist framework to build extensible HTTP servers and clients

Install

Dune Dependency

Authors

Maintainers

Sources

opium-0.20.0.tbz
sha256=326b91866de90baf535f8b7d4b2ff23e39d952e573c04b3c13f1054b59ff2fb6
sha512=59b83e7c8fe5f7ae328fb7f2343fe5b8fb735e8f6ee263cfd6c75bb179688ef7cf2b4586b35a2231ed3f3c1ada543021b7a4759326ae095eb77a5f38b9fa3a8a

doc/rock/Rock/index.html

Module RockSource

A tiny clone of ruby's Rack protocol in OCaml. Which is slightly more general and inspired by Finagle. It's not imperative to have this to for such a tiny framework but it makes extensions a lot more straightforward

Sourcemodule App : sig ... end
Sourcemodule Context : sig ... end

A context holds heterogeneous value and is passed to the requests or responses.

Sourcemodule Request : sig ... end

Module to create HTTP requests.

Sourcemodule Response : sig ... end

Module to create HTTP responses.

Sourcemodule Body : sig ... end

Represents an HTTP request or response body.

Sourcemodule Service : sig ... end

A service is a function that returns its result asynchronously.

Sourcemodule Filter : sig ... end

A filter is a higher order function that transforms a service into another service.

Sourcemodule Handler : sig ... end

A handler is a rock specific service.

Sourcemodule Middleware : sig ... end

Middleware is a named, simple filter, that only works on rock requests/response.

Sourcemodule Server_connection : sig ... end

Collection of functions to run a server from a Rock app.

OCaml

Innovation. Community. Security.