forked from openshift/operator-framework-olm
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(catsrc) add custom unmarshaller for registry poll interval (openshif…
…t#169) This PR implements a custom unmarshaller for the CatalogSourceSpec.UpdateStrategy. When a value that cannot be unmarshalled to *metav1.Duration was being passed to UpdateStrategy.RegistryPoll.Interval, the catalogSource sync loops in the catalog operator was stuck in an infinite loop instead of backing off and performing other syncs. The custom unmarshaller tries to unmarshall the input to the field to *metav1.Duration, and if it fails, it sets a default value of 15m for the field. Otherwise it accepts the value passed to the field. Upstream-repository: api Upstream-commit: 7c97612f258921a973da23fb55dcd77892401be4
- Loading branch information
1 parent
ca73a8c
commit cd27b06
Showing
3 changed files
with
135 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 32 additions & 3 deletions
35
vendor/github.com/operator-framework/api/pkg/operators/v1alpha1/catalogsource_types.go
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.