aboutsummaryrefslogtreecommitdiffstats
path: root/load_paths.rb
diff options
context:
space:
mode:
authoreileencodes <eileencodes@gmail.com>2015-02-18 18:37:35 -0500
committereileencodes <eileencodes@gmail.com>2015-02-18 18:54:37 -0500
commit95ee93892a07f90fdfd503c7ea07abf0fb397bec (patch)
treea0c181c35bcd0cd78bdd66c4e1b7cf0f8785f1b6 /load_paths.rb
parente334417b7804b721306e70dbd53d2d542c8f7847 (diff)
downloadrails-95ee93892a07f90fdfd503c7ea07abf0fb397bec.tar.gz
rails-95ee93892a07f90fdfd503c7ea07abf0fb397bec.tar.bz2
rails-95ee93892a07f90fdfd503c7ea07abf0fb397bec.zip
Freeze strings to reduce allocations in integration tests
Moves `X-Request-ID`, `action_dispatch.request_id` and `HTTP_X_REQUEST_ID` strings to constants and freezes them. We are freezing these strings to reduce the number of allocations in Rails integration tests. The tests are spending a lot of time in GC and this reduces the amount of time spent from 12% to 9% (in combination with Rack PR that also freezes some strings). Number of allocations before this change: 1030722 Number of allocations after this change: 967722
Diffstat (limited to 'load_paths.rb')
0 files changed, 0 insertions, 0 deletions