[erlang-questions] http:set_options/1 Problem (R13B)

Per Melin <>
Fri May 8 19:02:52 CEST 2009


Peter McCarthy:
> Hi all.
>
> When I do something like this:
>
>  http:set_options([{max_keep_alive_length, 10}]).
>
> I get the following result:
>
>  {error,{not_an_option,{max_keep_alive_length,10}}}
>
> Does anyone know if there is a typo in the documentation? Or is
> support for setting the maximum number of outstanding requests (on a
> connection) not implemented yet?

After a quick glance at the source (which should be the first course
of action for anyone faced with a question like this) I would say that
max_keep_alive_length is indeed implemented, but there is a bug in the
function http:validate_options/1. It does not have
max_keep_alive_length as a valid option, but instead has two identical
checks for max_pipeline_length. My guess is that someone was too fast
with the copy-paste.



More information about the erlang-questions mailing list