lib/dexter/processor.rb in pgdexter-0.3.10 vs lib/dexter/processor.rb in pgdexter-0.4.0
- old
+ new
@@ -60,10 +60,10 @@
process_queries_without_lock
end
end
def process_queries_without_lock
- now = Time.now
+ now = Process.clock_gettime(Process::CLOCK_MONOTONIC)
min_checked_at = now - 3600 # don't recheck for an hour
queries = []
@collector.fetch_queries.each do |query|
if !@last_checked_at[query.fingerprint] || @last_checked_at[query.fingerprint] < min_checked_at
queries << query