From 8b9e641c3da5081e079accf585fc3a3ad51034d1 Mon Sep 17 00:00:00 2001 From: Dante Soares Date: Mon, 1 Mar 2021 12:20:17 -0600 Subject: [PATCH 1/3] Added Puma 5.2 config options --- config/puma.rb | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/config/puma.rb b/config/puma.rb index 0fa2f105..79e8d8da 100644 --- a/config/puma.rb +++ b/config/puma.rb @@ -89,3 +89,10 @@ # Allow puma to be restarted by `rails restart` command. plugin :tmp_restart + +# Call GC.start and GC.compact before forking to try to reduce worker memory usage +nakayoshi_fork + +# Adds a small delay before accepting requests if the worker (process) has threads already +# processing other requests, to try to get idle workers to accept the request +wait_for_less_busy_worker ENV.fetch('WAIT_FOR_LESS_BUSY_WORKERS', '0.005').to_f From a8d8daae24a76d3c9700d169415b1727629691a2 Mon Sep 17 00:00:00 2001 From: Dante Soares Date: Mon, 1 Mar 2021 12:26:35 -0600 Subject: [PATCH 2/3] Updated to ruby 2.7 --- .ruby-version | 2 +- Gemfile | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.ruby-version b/.ruby-version index 6a6a3d8e..37c2961c 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.6.1 +2.7.2 diff --git a/Gemfile b/Gemfile index 66858fe7..8382a256 100644 --- a/Gemfile +++ b/Gemfile @@ -17,7 +17,6 @@ gem 'bootstrap-sass' # Use SCSS for stylesheets gem 'sass-rails', '~> 5.0' - # Use Uglifier as compressor for JavaScript assets gem 'uglifier', '>= 1.3.0' From 61ae5ce671b9e3b679f366d3d6d4434e8d28b29f Mon Sep 17 00:00:00 2001 From: Dante Soares Date: Mon, 1 Mar 2021 12:36:38 -0600 Subject: [PATCH 3/3] Updated GH actions ruby version to 2.7 --- .github/workflows/assets.yml | 2 +- .github/workflows/migrations.yml | 2 +- .github/workflows/tests.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/assets.yml b/.github/workflows/assets.yml index d38e7e59..834db28a 100644 --- a/.github/workflows/assets.yml +++ b/.github/workflows/assets.yml @@ -17,7 +17,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-ruby@v1 with: - ruby-version: 2.6 + ruby-version: 2.7 - uses: actions/cache@v2 with: path: vendor/bundle diff --git a/.github/workflows/migrations.yml b/.github/workflows/migrations.yml index 0bec99d1..d22991cc 100644 --- a/.github/workflows/migrations.yml +++ b/.github/workflows/migrations.yml @@ -44,7 +44,7 @@ jobs: # Install ruby - uses: actions/setup-ruby@v1 with: - ruby-version: 2.6 + ruby-version: 2.7 # Retrieve gem cache for merge commit parent - uses: actions/cache@v2 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 64ec0589..302e77ed 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-ruby@v1 with: - ruby-version: 2.6 + ruby-version: 2.7 - uses: actions/cache@v2 with: path: vendor/bundle