Skip to content

Conversation

@shawkins
Copy link
Contributor

closes: #7164

draft of changes to allow the ExceptionHandler to deal with reconnection exceptions as well.

To keep this compatible with current behavior the WatcherException is converted to a KubernetesClientException when passed into the the ExceptionHandler - by default that will mean we'll keep retrying.

Users would need to update / set their own ExceptionHandler to cause the informer to give up in this case. This is mostly inline with what was requested on #7164

Alternatives to this are:

  • Pass the exception in as a WatcherException, and let the informer stop watching - by itself this would be a breaking change.
  • Alternatively don't use the ExceptionHandler mechanism, and add Informer configuration for the number of watch reconnections it will attempt before giving up - it would default to unlimited for backwards compatibility. This is more inline with what is requested on Infinite loop in AbstractWatchManager #7365

cc @csviri @manusa @metacosm what would you like to see done here?

Description

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change
  • Chore (non-breaking change which doesn't affect codebase;
    test, version modification, documentation, etc.)

Checklist

  • Code contributed by me aligns with current project license: Apache 2.0
  • I Added CHANGELOG entry regarding this change
  • I have implemented unit tests to cover my changes
  • I have added/updated the javadocs and other documentation accordingly
  • No new bugs, code smells, etc. in SonarCloud report
  • I tested my code in Kubernetes
  • I tested my code in OpenShift

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SharedIndexInformer endlessly attempts to reconnect to the down Kube API server

1 participant