Skip to content

raise exception after exiting watcher.each #214

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Mar 18, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions lib/fluent/plugin/kubernetes_metadata_watch_namespaces.rb
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ def process_namespace_watcher_notices(watcher)
# ignore and let age out for cases where
# deleted but still processing logs
@stats.bump(:namespace_cache_watch_deletes_ignored)
when 'ERROR'
message = notice['object']['message'] if notice['object'] && notice['object']['message']
raise "Error while watching namespaces: #{message}"
else
# Don't pay attention to creations, since the created namespace may not
# be used by any namespace on this node.
Expand Down
3 changes: 3 additions & 0 deletions lib/fluent/plugin/kubernetes_metadata_watch_pods.rb
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,9 @@ def process_pod_watcher_notices(watcher)
# ignore and let age out for cases where pods
# deleted but still processing logs
@stats.bump(:pod_cache_watch_delete_ignored)
when 'ERROR'
message = notice['object']['message'] if notice['object'] && notice['object']['message']
raise "Error while watching pods: #{message}"
else
# Don't pay attention to creations, since the created pod may not
# end up on this node.
Expand Down