Skip to content

Commit

Permalink
Fix field set format
Browse files Browse the repository at this point in the history
Field sets are, like tag sets, separated with a comma and no spaces.
  • Loading branch information
hennevogel committed Jul 8, 2021
1 parent a83d008 commit 6398541
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/api/app/jobs/worker_measurements_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def send_worker_metrics
idle_state = @workerstatus.xpath("//idle[@hostarch=\"#{architecture_name}\"]").count
building_state = @workerstatus.xpath("//building[@hostarch=\"#{architecture_name}\"]").count

RabbitmqBus.send_to_bus('metrics', "worker,arch=#{architecture_name} dead=#{dead_state} down=#{down_state} away=#{away_state} idle=#{idle_state} building=#{building_state}")
RabbitmqBus.send_to_bus('metrics', "worker,arch=#{architecture_name} dead=#{dead_state},down=#{down_state},away=#{away_state},idle=#{idle_state},building=#{building_state}")
end
end

Expand All @@ -42,7 +42,7 @@ def send_job_metrics
hostarch = job.attributes['hostarch'].value
arch = job.attributes['arch'].value
progression = Time.now.to_i - job.attributes['starttime'].value.to_i
RabbitmqBus.send_to_bus('metrics', "jobs,hostarch=#{hostarch},arch=#{arch},state=building progression=#{progression} count=1")
RabbitmqBus.send_to_bus('metrics', "jobs,hostarch=#{hostarch},arch=#{arch},state=building progression=#{progression},count=1")
end
end

Expand All @@ -54,7 +54,7 @@ def send_scheduler_metrics
low = scheduler.attributes['low'].value
medium = scheduler.attributes['med'].value
next_count = scheduler.attributes['next'].value
RabbitmqBus.send_to_bus('metrics', "scheduler,arch=#{architecture},partition=#{partition} high=#{high} low=#{low} medium=#{medium} next=#{next_count}")
RabbitmqBus.send_to_bus('metrics', "scheduler,arch=#{architecture},partition=#{partition} high=#{high},low=#{low},medium=#{medium},next=#{next_count}")
end
end
end

0 comments on commit 6398541

Please sign in to comment.