Thanks! It solves my first issue :)
Second problem is this message:
[error] Error in simple_bridge_request:make/2 - exit - {body_too_large,content_length}
[{mochicow_request,stream_body,5,[{file,"src/mochicow_request.erl"},{line,323}]},{mochicow_request,recv_body,2,[{file,"src/mochicow_request.erl"},{line,275}]},{simple_bridge_multipart,parse_multipart,1,[{file,"src/simple_bridge_multipart.erl"},{line,69}]},{simple_bridge_request,make_nocatch,2,[{file,"src/simple_bridge_request.erl"},{line,23}]},{simple_bridge_request,make,2,[{file,"src/simple_bridge_request.erl"},{line,14}]},{boss_web_controller_handle_request,handle_request,3,[{file,"src/boss/boss_web_controller_handle_request.erl"},{line,17}]},{mochicow_upgrade,upgrade,4,[{file,"src/mochicow_upgrade.erl"},{line,72}]},{cowboy_protocol,execute,4,[{file,"src/cowboy_protocol.erl"},{line,529}]}]
In mochiweb_request_bridge.erl
there is a constant defined:
-define(MAX_RECV_BODY,(1024*1024*10)).
and it is used to define MaxBody like this:
141 MaxBody = case application:get_env(mochiweb,max_request_size) of
142 undefined ->
143 ?MAX_RECV_BODY;
144 {ok, Max} when is_integer(Max) ->
145 Max;
146 Other ->
147 error_logger:warning_msg("Mochiweb Simple Bridge Configuration Error! Unknown value for 'mochiweb' application variable 'max_request_size': ~p. Expected: integer()
148 ?MAX_RECV_BODY
149 end,
mochiweb application is never started, so get_env/2 will always return undefined.
It probably means, that I have no way to configure it :/
I have to change the hardcoded value.
Do you think, that it should also be configured as vm argument?
In that case, I can create pull request.