caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] ANN: webmachine.0.3.0
@ 2015-12-11 16:16 Spiros Eliopoulos
  0 siblings, 0 replies; only message in thread
From: Spiros Eliopoulos @ 2015-12-11 16:16 UTC (permalink / raw)
  To: OCaml

[-- Attachment #1: Type: text/plain, Size: 1238 bytes --]

Hi all,

I wanted to bring to your attention the latest release of webmachine,
weighing in at version 0.3.0. This release includes bugfixes and a few
major API changes. Most notably is the way that users must create redirect
responses. There was an ambiguity in the state machine when dealing with
POST requests and redirects. To allow both a Location header to be set for
a POST response and redirection, users should use the redirect function on
the Rd record like so:

  Webmachine.continue body (Rd.redirect "/path/to/resource" rd)

Setting the Location header for a POST response remains unchanged.

In addition, the is_authorized handler now deviates slightly from the
original Erlang implementation. The return type for that function now looks
like this:

  type auth =
    [ `Authorized        (* The request is authorized to proceed *)
    | `Basic of string   (* Basic authentication challenge[0] for the given
realm *)
    | `Redirect of Uri.t (* Use the given URI to authenticate *)
    ]

You can see the full list of changes in the release notes:

  https://github.com/inhabitedtype/ocaml-webmachine/releases/tag/0.3.0

As always, issues and pull requests are welcomed.

-Spiros E.

[0]: https://tools.ietf.org/html/rfc2617

[-- Attachment #2: Type: text/html, Size: 1711 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-12-11 16:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-11 16:16 [Caml-list] ANN: webmachine.0.3.0 Spiros Eliopoulos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).