Slightly reduce RAM usage (#7301)

* No need to re-require sidekiq plugins, they are required via Gemfile

* Add derailed_benchmarks tool, no need to require TTY gems in Gemfile

* Replace ruby-oembed with FetchOEmbedService

Reduce startup by 45382 allocated objects

* Remove preloaded JSON-LD in favour of caching HTTP responses

Reduce boot RAM by about 6 MiB

* Fix tests

* Fix test suite by stubbing out JSON-LD contexts
This commit is contained in:
Eugen Rochko
2018-05-02 18:58:48 +02:00
committed by GitHub
parent 71a7cea73f
commit cb5b5cb5f7
76 changed files with 784 additions and 471 deletions

View File

@ -75,6 +75,7 @@ GEM
aws-sigv4 (~> 1.0)
aws-sigv4 (1.0.2)
bcrypt (3.1.11)
benchmark-ips (2.7.2)
better_errors (2.4.0)
coderay (>= 1.0.0)
erubi (>= 1.0.0)
@ -138,6 +139,14 @@ GEM
css_parser (1.6.0)
addressable
debug_inspector (0.0.3)
derailed_benchmarks (1.3.4)
benchmark-ips (~> 2)
get_process_mem (~> 0)
heapy (~> 0)
memory_profiler (~> 0)
rack (>= 1)
rake (> 10, < 13)
thor (~> 0.19)
devise (4.4.3)
bcrypt (~> 3.0)
orm_adapter (~> 0.1)
@ -206,6 +215,7 @@ GEM
fuubar (2.3.1)
rspec-core (~> 3.0)
ruby-progressbar (~> 1.4)
get_process_mem (0.2.1)
globalid (0.4.1)
activesupport (>= 4.2.0)
goldfinger (2.1.0)
@ -226,6 +236,7 @@ GEM
concurrent-ruby (~> 1.0)
hashdiff (0.3.7)
hashie (3.5.7)
heapy (0.1.3)
highline (1.7.10)
hiredis (0.6.1)
hitimes (1.2.6)
@ -264,10 +275,6 @@ GEM
json-ld (2.2.1)
multi_json (~> 1.12)
rdf (>= 2.2.8, < 4.0)
json-ld-preloaded (2.2.3)
json-ld (>= 2.2, < 4.0)
multi_json (~> 1.12)
rdf (>= 2.2, < 4.0)
jsonapi-renderer (0.2.0)
jwt (2.1.0)
kaminari (1.1.1)
@ -502,7 +509,6 @@ GEM
rainbow (>= 2.2.2, < 4.0)
ruby-progressbar (~> 1.7)
unicode-display_width (~> 1.0, >= 1.0.1)
ruby-oembed (0.12.0)
ruby-progressbar (1.9.0)
ruby-saml (1.7.2)
nokogiri (>= 1.5.10)
@ -557,6 +563,7 @@ GEM
sshkit (1.16.0)
net-scp (>= 1.1.2)
net-ssh (>= 2.8.0)
stackprof (0.2.11)
statsd-ruby (1.2.1)
stoplight (2.1.3)
streamio-ffmpeg (3.0.2)
@ -645,6 +652,7 @@ DEPENDENCIES
chewy (~> 5.0)
cld3 (~> 3.2.0)
climate_control (~> 0.2)
derailed_benchmarks
devise (~> 4.4)
devise-two-factor (~> 3.0)
devise_pam_authenticatable2 (~> 9.1)
@ -668,7 +676,7 @@ DEPENDENCIES
i18n-tasks (~> 0.9)
idn-ruby
iso-639
json-ld-preloaded (~> 2.2)
json-ld (~> 2.2)
kaminari (~> 1.1)
letter_opener (~> 1.4)
letter_opener_web (~> 1.3)
@ -714,7 +722,6 @@ DEPENDENCIES
rspec-retry (~> 0.5)
rspec-sidekiq (~> 3.0)
rubocop (~> 0.55)
ruby-oembed (~> 0.12)
ruby-progressbar (~> 1.4)
sanitize (~> 4.6)
scss_lint (~> 0.57)
@ -726,6 +733,7 @@ DEPENDENCIES
simple_form (~> 4.0)
simplecov (~> 0.16)
sprockets-rails (~> 3.2)
stackprof
stoplight (~> 2.1.3)
streamio-ffmpeg (~> 3.0)
strong_migrations (~> 0.2)