lib/postgres/vacuum/jobs/monitor_job.rb in postgres-vacuum-monitor-0.13.0 vs lib/postgres/vacuum/jobs/monitor_job.rb in postgres-vacuum-monitor-0.13.1
- old
+ new
@@ -16,11 +16,11 @@
connection.execute(Postgres::Vacuum::Monitor::Query.long_running_transactions).each do |row|
reporter_class.report_event(
LONG_TRANSACTIONS,
database_name: name,
start_time: row['xact_start'],
- running_time: row['seconds'],
+ running_time: row['seconds'].to_i,
application_name: row['application_name'],
most_recent_query: row['query'],
state: row['state'],
wait_event_type: row['wait_event_type'],
transaction_id: row['backend_xid'],
@@ -63,12 +63,12 @@
connection.execute(Postgres::Vacuum::Monitor::Query.connection_idle_time).each do |row|
reporter_class.report_event(
CONNECTION_IDLE_TIME,
database_name: name,
- max: row['max'],
- median: row['median'],
- percentile_90: row['percentile_90']
+ max: row['max'].to_i,
+ median: row['median'].to_i,
+ percentile_90: row['percentile_90'].to_i
)
end
end
true