What is Rack::Utils.multipart_part_limit within Rails and what function does it perform?

1.5k views Asked by At

Rack::Utils.multipart_part_limit is set to 128 by default.

What purpose does the value have and what effect does it have within the Rails system?

1

There are 1 answers

0
Glupo On BEST ANSWER

Telling it short, this value limits the amount of simultaneously opened files for multipart requests. To understand better what is multipart, you can see this question.

The reason for this limitation is an ability to better adjust your app for your server. If you have too many files opened at a time, your system can run out of handles. If you are not worried of this you can set this value to 0 in your initializer like this Rack::Utils.multipart_part_limit = 0