[erlang-questions] Problems with ibrowse 1.5.2 - send_req not causing stream_to

Vik Olliver vik@REDACTED
Fri Aug 28 02:07:14 CEST 2009


On 27/08/09 Chandru wrote:
>  May I see a bit of your code which handles the responses? For async
>  requests, if an error happens in handling them, ibrowse sends back:
>  {ibrowse_async_response, Req_id, Err} and never sends back a
>  {ibrowse_async_response_end, Req_id}.

That might explain what's going on. It's certainly something I've not 
got debug trace on:

handle_info({ibrowse_async_response_end, _}, State) ->

    {noreply, State};

handle_info({ibrowse_async_response, _, _}, State) ->

    {noreply, State};

handle_info({ibrowse_async_headers, ReqId, Code, _Headers}, State) ->

    {noreply, end_deliver(State, ReqId, Code)};

handle_info(Info, State) ->

    ?WARN("Unexpected info ~p", [Info]),

    {noreply, State}.

It appears that this code is not doing anything interesting with 
{ibrowse_async_response, Req_id, Err} - and I can see a flaw there 
straight away :) It's a wonder it worked for so long...

Vik :v)


More information about the erlang-questions mailing list