-
Notifications
You must be signed in to change notification settings - Fork 696
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Req.Body Truncated in Versions >= 1.6.0 #41
Comments
Yea. You need to either use It also seems like you're sending a really big object over urlencoded. Perhaps you just want to use JSON :)? |
and in case you were wondering, the reason this changed in a non-major version is because using |
Ah, yes, I forgot Node.js core also has a default limit of 1,000 parameters (though it's limit is configurable): https://github.com/joyent/node/blob/v0.10.24/lib/querystring.js#L172 I'm going to talk with the |
Awesome. I appreciate your help. |
So for the extended module, there is no way right now it can even handle > 1000 parameters. Feeding it 2000 parameters make it take ~1710ms on my machine, an eternity. |
If you wish to keep using very large urlencoded payloads, you will be able to configure the limit in the upcoming 1.7.0: app.use(bodyParser.urlencoded({ extended: true, parameterLimit: 5000 })) |
In addition, the module will no longer give you weird truncated |
Are the 1710ms a pathological example or is this really the expected runtime for parsing 2000 elements? It seems like a lot. |
It is a real example. |
Ah, thanks. Glad to hear that, got me nervous for a minute! :) |
Upon updating my project dependencies I realized that url encoded data originating from my client app seemed to be getting severely truncated. Installing previous tags back to 1.5.x seemed to remedy the problem.. 2 quick screenshots illustrate these issues:
installed tag 1.5.2
![bp-1 5 2](https://cloud.githubusercontent.com/assets/1649194/4033231/a4e1dc26-2c78-11e4-9c1f-4529bb3abbd5.jpg)
installed tag 1.6.0
![bp-1 6 0](https://cloud.githubusercontent.com/assets/1649194/4033243/bd844336-2c78-11e4-98dd-eb64390ac0df.jpg)
Big difference!
Haven't pinned down the change that's responsible for this error, but I thought you should know about this. I'm sticking with the 1.5's for the time being.
Thanks.
The text was updated successfully, but these errors were encountered: