From fb6aa7ad5ce79ae0738ebf1cada0e834c33b0ef2 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sun, 5 Feb 2017 03:19:04 +0100 Subject: Add tracking of delay to streaming API --- app/lib/feed_manager.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'app/lib') diff --git a/app/lib/feed_manager.rb b/app/lib/feed_manager.rb index 028fc5218..7069026e3 100644 --- a/app/lib/feed_manager.rb +++ b/app/lib/feed_manager.rb @@ -30,6 +30,7 @@ class FeedManager end def broadcast(timeline_id, options = {}) + options[:queued_at] = (Time.now.to_f * 1000.0).to_i ActionCable.server.broadcast("timeline:#{timeline_id}", options) end -- cgit