# frozen_string_literal: true module Wayfarer # TODO: Add logging module GC RESETTABLES = [Wayfarer::Redis::Barrier, Wayfarer::Redis::Counter].freeze class << self include Wayfarer::Logging.emit(gc: [:info, "Garbage collecting %s"]) end module_function def run(task) RESETTABLES.each do |resettable| log(:gc, task, resettable: resettable) resettable.new(task).reset! end end end end