diff --git a/app/views/projects/build_lists/_server_status.html.haml b/app/views/projects/build_lists/_server_status.html.haml index 33564267d..e1d56b0ab 100644 --- a/app/views/projects/build_lists/_server_status.html.haml +++ b/app/views/projects/build_lists/_server_status.html.haml @@ -28,7 +28,11 @@ .table .lefter= t("layout.build_lists.build_server_status.publish_workers") .both - - [:workers, :tasks, :build_tasks].each do |metric| + .table + .lefter= t("layout.build_lists.build_server_status.amount") + .righter= "{{server_status.publish.workers}}" + .both + - [:tasks, :build_tasks].each do |metric| .table .lefter= t("layout.build_lists.build_server_status.#{metric}") .righter= "{{server_status.publish.#{metric}}}" diff --git a/lib/abf_worker/status_inspector.rb b/lib/abf_worker/status_inspector.rb index 852f15f52..54e10fcad 100644 --- a/lib/abf_worker/status_inspector.rb +++ b/lib/abf_worker/status_inspector.rb @@ -6,9 +6,12 @@ module AbfWorker Rails.cache.fetch([AbfWorker::StatusInspector, :projects_status], :expires_in => 10.seconds) do result = get_status(:rpm, :publish) { |w, worker| w.to_s =~ /#{worker}_worker_default/ } nodes = RpmBuildNode.total_statistics - result[:rpm][:workers] += nodes[:systems] - result[:rpm][:build_tasks] += nodes[:busy] - result[:rpm][:other_workers] = nodes[:others] + result[:rpm][:workers] += nodes[:systems] + result[:rpm][:build_tasks] += nodes[:busy] + result[:rpm][:other_workers] = nodes[:others] + external_bls = BuildList.for_status(BuildList::BUILD_PENDING).external_nodes(:everything).count + result[:rpm][:default_tasks] += external_bls + result[:rpm][:tasks] += external_bls result end end