From afa5eeb5fd42262dbc5770fca789c9d111b31ddc Mon Sep 17 00:00:00 2001 From: Priit Tark Date: Thu, 16 Jul 2015 15:53:58 +0300 Subject: [PATCH 1/3] Fix que doc #2724 --- doc/que/que-init-example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/que/que-init-example b/doc/que/que-init-example index d36fbf101..9e561d3a8 100644 --- a/doc/que/que-init-example +++ b/doc/que/que-init-example @@ -38,7 +38,7 @@ start) ;; stop) echo "$1 que monitor and server" - cd $APP_ROOT && RAILS_ENV=$RAILS_ENV $RUBY_BUNDLE_PATH lib/daemons/que_ctl stop + cd $APP_ROOT && RAILS_ENV=$RAILS_ENV $RUBY_BUNDLE_PATH exec lib/daemons/que_ctl stop ;; restart) echo "$1 que monitor and server" From 0918a2669188a41d351102c8e2a0e9472adc65d1 Mon Sep 17 00:00:00 2001 From: Priit Tark Date: Mon, 20 Jul 2015 12:28:04 +0300 Subject: [PATCH 2/3] Wake que less often, now every 1 second instead of 0.01 second #2724 --- lib/daemons/que.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/daemons/que.rb b/lib/daemons/que.rb index 683024ddd..cc80295ff 100755 --- a/lib/daemons/que.rb +++ b/lib/daemons/que.rb @@ -19,7 +19,7 @@ end Que.logger.level = Logger.const_get((ENV['QUE_LOG_LEVEL'] || 'INFO').upcase) Que.worker_count = 1 -Que.wake_interval = (ENV['QUE_WAKE_INTERVAL'] || 0.1).to_f +Que.wake_interval = (ENV['QUE_WAKE_INTERVAL'] || 1).to_f Que.mode = :async # When changing how signals are caught, be sure to test the behavior with @@ -38,6 +38,6 @@ at_exit do end loop do - sleep 0.01 + sleep 1 break if stop end From 12abb973874892af0bce4d345e2dd088bfcc6427 Mon Sep 17 00:00:00 2001 From: Priit Tark Date: Tue, 21 Jul 2015 13:11:19 +0300 Subject: [PATCH 3/3] Replaced remote ip to ip for counter #2348 --- app/controllers/epp_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/epp_controller.rb b/app/controllers/epp_controller.rb index 2cd1c8bc7..5425c8b57 100644 --- a/app/controllers/epp_controller.rb +++ b/app/controllers/epp_controller.rb @@ -328,6 +328,6 @@ class EppController < ApplicationController def iptables_counter_update return if ENV['iptables_counter_enabled'].blank? && ENV['iptables_counter_enabled'] != 'true' return if current_user.blank? - counter_update(current_user.registrar_code, request.remote_ip) + counter_update(current_user.registrar_code, request.ip) end end