[web-devel] Last call for comments: WAI 0.4

Michael Snoyman michael at snoyman.com
Fri Apr 1 09:31:31 CEST 2011


On Fri, Apr 1, 2011 at 9:22 AM, Kazu Yamamoto <kazu at iij.ad.jp> wrote:
> Hello,
>
>> 2) None of the WAI backends do anything particularly intelligent with
>> the data. I think they all just print to stderr.
>
> It's OK for me to remove errorHandle from Request. But I want "warp"
> to provide a hook to handle errors. That is, please don't remove
> settingsOnException from Settings and you don't have to pass it to
> each Request but please use it inside of warp.

Don't worry, that feature of Warp is completely separate, and will
definitely be staying.

By the way, I've just finished a cleanup of the Warp API: the idea is
to provide three run functions only:

* run, same as now, only allows customizing the port
* runSettings allows configuring all settings (for now, port,
exception handler and timeout)
* runSettingsSocket allows you to provide both the Settings and the
socket to be listened on

I think these changes make the names simpler (no more
serveConnections) and remove redundant functions (runEx). If everyone
interested can take a look at the repo[1] and let me know if I'm
missing something obvious, I'd appreciate it.

Michael

[1] https://github.com/snoyberg/warp/blob/master/Network/Wai/Handler/Warp.hs



More information about the web-devel mailing list