Skip to content

Commit b8207ae

Browse files
committed
lets try puma
1 parent a6e3b87 commit b8207ae

File tree

6 files changed

+22
-33
lines changed

6 files changed

+22
-33
lines changed

Gemfile

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@ source 'https://rubygems.org'
33
ruby '2.4.4'
44

55
gem 'travis-support', git: 'https://github.com/travis-ci/travis-support', ref: '113cff17fe383bb72fcfae3a97a8ce98c228342f'
6-
gem 'travis-config', '~> 1.0.0'
6+
gem 'travis-config', '~> 1.0.0'
77

88
gem 'sidekiq', '~> 4.0.0'
99
gem 'redis-namespace'
1010

11+
gem 'puma'
1112
gem 'sinatra', '~> 2.0.0'
1213
gem 'rake', '~> 0.9.2.2'
1314

@@ -18,12 +19,8 @@ gem 'activesupport', '~> 4.1.11'
1819
gem 'metriks'
1920
gem 'metriks-librato_metrics'
2021

21-
# structures
2222
gem 'yajl-ruby', '~> 1.4.0'
2323

24-
# heroku
25-
gem 'unicorn', '~> 4.6.2'
26-
2724
gem 'jemalloc', git: 'https://github.com/joshk/jemalloc-rb'
2825

2926
group :development, :test do

Gemfile.lock

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ GEM
2020
minitest (~> 5.1)
2121
thread_safe (~> 0.1)
2222
tzinfo (~> 1.1)
23-
atomic (1.1.99)
23+
atomic (1.1.100)
2424
avl_tree (1.2.1)
2525
atomic (~> 1.1)
2626
coderay (1.1.2)
@@ -36,7 +36,6 @@ GEM
3636
i18n (0.9.5)
3737
concurrent-ruby (~> 1.0)
3838
json (1.8.6)
39-
kgio (2.11.2)
4039
method_source (0.9.0)
4140
metriks (0.9.9.8)
4241
atomic (~> 1.0)
@@ -50,12 +49,12 @@ GEM
5049
pry (0.11.3)
5150
coderay (~> 1.1.0)
5251
method_source (~> 0.9.0)
52+
puma (3.11.4)
5353
rack (2.0.5)
5454
rack-protection (2.0.1)
5555
rack
5656
rack-test (1.0.0)
5757
rack (>= 1.0, < 3)
58-
raindrops (0.19.0)
5958
rake (0.9.2.2)
6059
redis (3.3.5)
6160
redis-namespace (1.6.0)
@@ -86,10 +85,6 @@ GEM
8685
hashr (~> 2.0.0)
8786
tzinfo (1.2.5)
8887
thread_safe (~> 0.1)
89-
unicorn (4.6.3)
90-
kgio (~> 2.6)
91-
rack
92-
raindrops (~> 0.7)
9388
yajl-ruby (1.4.0)
9489

9590
PLATFORMS
@@ -102,6 +97,7 @@ DEPENDENCIES
10297
metriks
10398
metriks-librato_metrics
10499
pry
100+
puma
105101
rack-test
106102
rake (~> 0.9.2.2)
107103
redis-namespace
@@ -111,7 +107,6 @@ DEPENDENCIES
111107
sinatra (~> 2.0.0)
112108
travis-config (~> 1.0.0)
113109
travis-support!
114-
unicorn (~> 4.6.2)
115110
yajl-ruby (~> 1.4.0)
116111

117112
RUBY VERSION

Procfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
web: bundle exec je unicorn -p $PORT -c ./config/unicorn.rb
1+
web: bundle exec puma -C config/puma.rb
22
console: bundle exec irb -I lib -r travis/listener

config/puma.rb

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
workers Integer(ENV['WEB_CONCURRENCY'] || 2)
2+
threads_count = Integer(ENV['RAILS_MAX_THREADS'] || 5)
3+
threads threads_count, threads_count
4+
5+
preload_app!
6+
7+
rackup DefaultRackup
8+
port ENV['PORT'] || 3000
9+
environment ENV['RACK_ENV'] || 'development'
10+
11+
on_worker_boot do
12+
if reporter = Travis::Metrics.reporter
13+
reporter.stop
14+
reporter.start
15+
end
16+
end

config/unicorn.rb

Lines changed: 0 additions & 15 deletions
This file was deleted.

travis-listener.gemspec

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)