Skip to content

Conversation

snoopcatt
Copy link
Contributor

Problem: when you set tnt_pass_http_request to parse_args parse_urlencoded pass_body, it's impossible to access raw POST body even if there are binary file, for example.

This problem caused because parse_urlencoded conflicts with pass_body.

In this patch, I've splitted these options to allow them work together.
Config parameters is backward compatible with upstream.

pass_body will allow you to access request variable body that containts unparsed request body.
parse_urlencoded will allow you to access new request variable args_urlencoded that will contain table with parsed POST request (like args for GET)

NB! If you using parse_urlencoded now, you need to change req.body to req.args_urlencoded in your Lua code. If you using only pass_body, no need to change anything.

…urlencoded" enabled. Args parsed from POST data now stored in (req.args_urlencoded) request variable.
@dedok dedok self-requested a review November 6, 2019 17:00
@dedok dedok merged commit daccb2a into tarantool:master Nov 6, 2019
@dedok
Copy link
Contributor

dedok commented Nov 6, 2019

Thank you for contributing! Looks good to me.

@Totktonada Totktonada linked an issue Dec 14, 2020 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants