From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by sympa.inria.fr (Postfix) with ESMTPS id B80EC7FD8B for ; Fri, 11 Dec 2015 17:17:17 +0100 (CET) IronPort-PHdr: 9a23:b/OIHhJRf4+NwokO/dmcpTZWNBhigK39O0sv0rFitYgULvTxwZ3uMQTl6Ol3ixeRBMOAu6wC0rud4/2ocFdDyKjCmUhKSIZLWR4BhJdetC0bK+nBN3fGKuX3ZTcxBsVIWQwt1Xi6NU9IBJS2PAWK8TWM5DIfUi/yKRBybrysXNWC0YLuhqviptX6WEZhunmUWftKNhK4rAHc5IE9oLBJDeIP8CbPuWZCYO9MxGlldhq5lhf44dqsrtY4q3wD86Fpy8kVdo7zeqBwGbdRCTBjN2Eu+OXqswPCRE2B/C1PfH8Rl09zGwnf6wqyc5PwtTP9q+56w2HOJsDyTLcsXimK4KJiSRuugyACYW1quFrLg9B92foI6CmqoAZyltbZ Authentication-Results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=seliopou@gmail.com; spf=Pass smtp.mailfrom=seliopou@gmail.com; spf=None smtp.helo=postmaster@mail-lf0-f49.google.com Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of seliopou@gmail.com) identity=pra; client-ip=209.85.215.49; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="seliopou@gmail.com"; x-sender="seliopou@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail2-smtp-roc.national.inria.fr: domain of seliopou@gmail.com designates 209.85.215.49 as permitted sender) identity=mailfrom; client-ip=209.85.215.49; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="seliopou@gmail.com"; x-sender="seliopou@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-lf0-f49.google.com) identity=helo; client-ip=209.85.215.49; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="seliopou@gmail.com"; x-sender="postmaster@mail-lf0-f49.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0A0AACM9mpWmzHXVdFehA1uBrJtijwBDYFiFwEJhW6BKgc4FAEBAQEBAQEBEAEBAQEBBgsLCSEugi2CIBEdARseAxIDBgc3AiQBEQEFASI1h3cBAxINj0+NRoIIgTE+MYtIgWqCeYgDChknDVaDZwwBGgEBBA6GSIoFgjUMLhOBNgWFWYhQiEmFNYVUgjuBW40ZiimCJhIkgRcfAQGCRiOBeyA0AYVkAQEB X-IPAS-Result: A0A0AACM9mpWmzHXVdFehA1uBrJtijwBDYFiFwEJhW6BKgc4FAEBAQEBAQEBEAEBAQEBBgsLCSEugi2CIBEdARseAxIDBgc3AiQBEQEFASI1h3cBAxINj0+NRoIIgTE+MYtIgWqCeYgDChknDVaDZwwBGgEBBA6GSIoFgjUMLhOBNgWFWYhQiEmFNYVUgjuBW40ZiimCJhIkgRcfAQGCRiOBeyA0AYVkAQEB X-IronPort-AV: E=Sophos;i="5.20,414,1444687200"; d="scan'208";a="191605116" Received: from mail-lf0-f49.google.com ([209.85.215.49]) by mail2-smtp-roc.national.inria.fr with ESMTP/TLS/AES128-GCM-SHA256; 11 Dec 2015 17:17:09 +0100 Received: by lfdl133 with SMTP id l133so81449821lfd.2 for ; Fri, 11 Dec 2015 08:17:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=QhKMm9oXxGDtR9EAL5adCWhEXaYEk4C4AEmpETvQjVk=; b=d33gaTuaJzW7Sh6hr9zXDTAba1tBv3FmUDWMsFY81G1YeqCReXRCAGcyMZ3pt5sd+f 2Y5JcKzhR9nrRrjqrWr9jzlhKkLa9FEHqaKBscpp/XI+y0dH7LE84FqNHeyEs55nhsIv zML/ezK9MNaQn9chHIEKHjASuqyGKCHfLNPFdIGDBiQfXmV6DGtqFHvOYCuShPLvdCeI iKzgccclgWcaNRJOen7pqjpy94ylv29o0qhYhiPC0y6yCguiux5yLAtmWjywX28EB3yP bzw9k9lVXaLBapg4sCShtW8y8HENEMfDnEK8I4PfPOIT1w+UQmu2XlrQ218iJaK47sGa oRgw== X-Received: by 10.25.166.146 with SMTP id p140mr8756033lfe.51.1449850623538; Fri, 11 Dec 2015 08:17:03 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.198.196 with HTTP; Fri, 11 Dec 2015 08:16:44 -0800 (PST) From: Spiros Eliopoulos Date: Fri, 11 Dec 2015 11:16:44 -0500 Message-ID: To: OCaml Content-Type: multipart/alternative; boundary=001a114118ac64ba7f0526a1a76a Subject: [Caml-list] ANN: webmachine.0.3.0 --001a114118ac64ba7f0526a1a76a Content-Type: text/plain; charset=UTF-8 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 --001a114118ac64ba7f0526a1a76a Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi all,

I wanted to bring to your atten= tion the latest release of webmachine, weighing in at version 0.3.0. This r= elease includes bugfixes and a few major API changes. Most notably is the w= ay 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 sho= uld use the redirect function on the Rd record like so:

=C2=A0 Webmachine.continue body (Rd.redirect "/path/to/resource&= quot; rd)

Setting the Location header for a POST r= esponse remains unchanged.

In addition, the is_aut= horized handler now deviates slightly from the original Erlang implementati= on. The return type for that function now looks like this:

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

You can see the full list of changes in the release n= otes:


As = always, issues and pull requests are welcomed.

-Sp= iros E.

--001a114118ac64ba7f0526a1a76a--