diff options
author | rhenium <re4k@re4k.info> | 2013-05-11 09:24:54 +0900 |
---|---|---|
committer | rhenium <re4k@re4k.info> | 2013-05-11 09:24:54 +0900 |
commit | 16498094d4b019a3b8240de1c0a2d31ac101136f (patch) | |
tree | b4c18f482617b02a0bb853fcaa9b166217c18179 | |
parent | 73fc0f1c0fbcc71743df2b8fba3c155986cf4cf9 (diff) | |
download | aclog-16498094d4b019a3b8240de1c0a2d31ac101136f.tar.gz |
update collector: add logging when unauthorized
-rw-r--r-- | collector/stream.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/collector/stream.rb b/collector/stream.rb index 5220471..d6e8267 100644 --- a/collector/stream.rb +++ b/collector/stream.rb @@ -30,9 +30,11 @@ module Aclog @client.on_reconnect {|timeout, retries| log(:warn, "Reconnected", retries) } @client.on_max_reconnects {|timeout, retries| + @client.connection.stop log(:warn, "Reached max reconnects", retries) } @client.on_unauthorized { log(:warn, "Unauthorized") + @client.connection.stop @callback.call(type: "unauthorized", user_id: @user_id, id: @account_id) } @client.each do |chunk| |