From 3e861efe5f76317419e0ba57f547c823ca8143f2 Mon Sep 17 00:00:00 2001 From: Vokhmin Alexey V Date: Fri, 24 May 2013 12:47:35 +0400 Subject: [PATCH] #142: update text labels --- app/views/projects/build_lists/_server_status.html.haml | 6 +++--- config/locales/models/build_list.en.yml | 8 ++++---- config/locales/models/build_list.ru.yml | 8 ++++---- lib/abf_worker/status_inspector.rb | 2 +- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/app/views/projects/build_lists/_server_status.html.haml b/app/views/projects/build_lists/_server_status.html.haml index c8cb6b0c6..18ca54d2d 100644 --- a/app/views/projects/build_lists/_server_status.html.haml +++ b/app/views/projects/build_lists/_server_status.html.haml @@ -7,8 +7,8 @@ .lefter= t("layout.build_lists.build_server_status.rpm_workers") .both .table - .lefter= t("layout.build_lists.build_server_status.count") - .righter= @build_server_status[:rpm][:count] + .lefter= t("layout.build_lists.build_server_status.workers") + .righter= @build_server_status[:rpm][:workers] .both .table .lefter= t("layout.build_lists.build_server_status.tasks") @@ -27,7 +27,7 @@ .table .lefter= t("layout.build_lists.build_server_status.#{queue}_workers") .both - - [:count, :tasks, :build_tasks].each do |metric| + - [:workers, :tasks, :build_tasks].each do |metric| .table .lefter= t("layout.build_lists.build_server_status.#{metric}") - if metric == :tasks diff --git a/config/locales/models/build_list.en.yml b/config/locales/models/build_list.en.yml index 1d1b325d1..af9d36c1e 100644 --- a/config/locales/models/build_list.en.yml +++ b/config/locales/models/build_list.en.yml @@ -99,14 +99,14 @@ en: build_server_status: header: Build server status - count: '- count' + workers: '- count' tasks: '- tasks in queue' user_tasks: "-- user's" mass_build_tasks: "-- mass build's" build_tasks: '- tasks in execution' - rpm_workers: Workers for building - iso_workers: Workers for building - publish_workers: Workers for publishing + rpm_workers: Workers of building + iso_workers: Workers of building + publish_workers: Workers of publishing items: statuses: diff --git a/config/locales/models/build_list.ru.yml b/config/locales/models/build_list.ru.yml index f13141c18..eaebe4ddc 100644 --- a/config/locales/models/build_list.ru.yml +++ b/config/locales/models/build_list.ru.yml @@ -98,14 +98,14 @@ ru: build_server_status: header: Статус сборочного сервера - count: '- число' + workers: '- число' tasks: '- заданий в очереди' user_tasks: '-- пользовательских' mass_build_tasks: '-- массовой сборки' build_tasks: '- заданий выполняется' - rpm_workers: Воркеров для сборки - iso_workers: Воркеров для сборки - publish_workers: Воркеров для публикации + rpm_workers: Воркеры сборки + iso_workers: Воркеры сборки + publish_workers: Воркеры публикации items: statuses: diff --git a/lib/abf_worker/status_inspector.rb b/lib/abf_worker/status_inspector.rb index 75c8f7308..8693954c3 100644 --- a/lib/abf_worker/status_inspector.rb +++ b/lib/abf_worker/status_inspector.rb @@ -30,7 +30,7 @@ module AbfWorker redis, key = Resque.redis, "queue:#{worker}_worker" default_tasks, tasks = redis.llen("#{key}_default"), redis.llen(key) { - :count => workers.count, + :workers => workers.count, :build_tasks => workers.select{ |w| w.working? }.count, :default_tasks => redis.llen("#{key}_default"), :low_tasks => redis.llen(key)