Open quape opened 8 years ago
+1
In my case, I had followed issue #710 and increased the limit on the urlencoded
parser. This solution appears to overwrite the default configuration (which includes the json parser), so I had to add it to the solution in order for both the large requests to be accepted and also get request.body
to be populated.
Router.configureBodyParsers = function () {
Router.onBeforeAction(Iron.Router.bodyParser.json());
Router.onBeforeAction(Iron.Router.bodyParser.urlencoded({
extended: true,
limit : '500mb'
}));
};
@micahalcorn can you explain me? it doesnt work with me.
I'm sending a json-ecoded POST request from outside to meteor which shall be captured by iron router like this:
This works when the request is small. When it is about 1 MB, I get a
Error: Request Entity Too Large
. So I used:to increase the request size limit. But then, this.request.body is empty. What to do?