Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisBr committed Feb 10, 2025
1 parent 3d0ad0d commit ced6a24
Showing 1 changed file with 20 additions and 3 deletions.
23 changes: 20 additions & 3 deletions ruby/lib/ci/queue/redis/worker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,29 @@ def poll
# only the master should perform this check because otherwise we will DDoS Redis when all workers
# try to fetch the processed tests at the same time
if master?
executed_tests = redis.smembers(key('success-reports')) + redis.hkeys(key('error-reports'))
ids = @index.keys.map { |id| id.dup.force_encoding(Encoding::BINARY) }
missing_tests = ids - executed_tests

if exhausted? &&
(missing_tests = @index.keys - (redis.smembers(key('success-reports')) + redis.hkeys(key('error-reports')))) &&
missing_tests.size > 0
if exhausted? && missing_tests.size > 0
puts "ci-queue did not process all tests!"
puts missing_tests.inspect

puts "--------------------------------"

missing_tests.each do |test|
puts test.inspect
end

puts "--------------------------------"
foo = executed_tests - ids
puts foo.inspect
puts "--------------------------------"

foo.each do |test|
puts test.inspect
end

end
end

Expand Down

0 comments on commit ced6a24

Please sign in to comment.