anchor.diff:  		message_parsing_error ->
   			<<"{\"ws_error\": \"Protocol message parsing error\"}">>;
   		_ ->
  -			{RequestMethod, Path, QueryString, ServerName, ServerPort} = Handler:request_info_for_message(ProtocolMessage),
  +			{RequestMethod, Path, QueryString, ServerName, ServerPort} = Handler:request_info_for_message(ProtocolMessage, HandlerState),
   			{ok, {Status, Headers, Body}} = perform_rack_request(RequestMethod, Path, QueryString, ServerName, ServerPort, ServerPath),
  -			Handler:encode_rack_response(Status, Headers, Body)
  +			Handler:encode_rack_response(Status, Headers, Body, HandlerState)
   	end,
  -	WSResponse = Handler:encode_transport_response(Response, ProtocolMessage),
  +	WSResponse = Handler:encode_transport_response(Response, ProtocolMessage, HandlerState),
       {reply, {text, WSResponse}, Req, State};
   
   websocket_handle(_Data, Req, State) ->
  
positive.code: websocket_info({timeout, _Ref, Msg}, Req, State) ->
  	{reply, {text, Msg}, Req, State};
  
  websocket_info(reconnect, Req, #state{path = _ServerPath, handler = Handler} = State) ->
    ReconnectMessage = Handler:handle_reconnect(State),
    {reply, {text, ReconnectMessage}, Req, State};
  
  websocket_info(_Info, Req, State) ->
  
negative.code: -record(state, {
    	path,
    	handler,
      ws_handler_pid,
      ws_handler_state
  }).
  
  %%% Gen_event behaviour methods
  