pkg/apis/duck
Matt Moore 31649c272a Start to lay the groundwork for Status conversion. (#373)
The backbone of our Condition system is our "happy" condition and
the semantics governing how other subconditions influence that condition.
When looking towards Conversion, it is possible for the set of conditions
to vary between `v1alpha1` and `v1beta1`, but the "happy" condition should
remain consistent across versions.

The main changes:
1. Provide a `ConvertTo` helper for "converting" between `duckv1beta1.Status`
 types in this "lowest common denominator" sense, where we just copy the
 happy condition.
2. When `InitializeConditions()` (plural) is called, seed the initial state
 of sub-conditions from the initial state of the "happy" condition, if True.

This change enables us to completely change the condition space across
versions, while maintaining the consistency of the happy condition.

A couple peripheral changes:
1. Add `context.Context` to the `apis.Convertible` interface.
2. Drop `InitializeCondition()` (singular) from the `ConditionsManager` interface (I don't see any usage outside of this file).
2019-04-09 08:22:59 -07:00
..
v1alpha1 Address some lint errors (#351) 2019-04-05 08:52:57 -07:00
v1beta1 Start to lay the groundwork for Status conversion. (#373) 2019-04-09 08:22:59 -07:00
OWNERS WIP Define a package with which to support duck typed definitions. (#71) 2018-09-15 19:08:17 -07:00
cached.go Informers / Listers for Duck Types. (#86) 2018-09-24 20:10:20 -07:00
cached_test.go Informers / Listers for Duck Types. (#86) 2018-09-24 20:10:20 -07:00
doc.go Link to the doc on Duck Typing, which I missed adding before. (#105) 2018-09-28 16:33:22 -07:00
enqueue.go Informers / Listers for Duck Types. (#86) 2018-09-24 20:10:20 -07:00
enqueue_test.go Informers / Listers for Duck Types. (#86) 2018-09-24 20:10:20 -07:00
interface.go Informers / Listers for Duck Types. (#86) 2018-09-24 20:10:20 -07:00
patch.go Undo the patch sorting. (#192) 2018-12-05 15:04:26 -08:00
patch_test.go Address some lint errors (#351) 2019-04-05 08:52:57 -07:00
podspec_test.go Move the use of `VerifyType` in tests (#98) 2018-09-27 15:16:22 -07:00
proxy.go Add logic to convert the watch.Interface. (#106) 2018-09-29 21:38:22 -07:00
register.go WIP Define a package with which to support duck typed definitions. (#71) 2018-09-15 19:08:17 -07:00
scale_test.go Add a test that shows modeling /scale as a duck. (#112) 2018-10-04 09:48:24 -07:00
typed.go Add logic to convert the watch.Interface. (#106) 2018-09-29 21:38:22 -07:00
typed_test.go Drop spec.generation support (#234) 2019-02-14 08:29:45 -08:00
unstructured.go Informers / Listers for Duck Types. (#86) 2018-09-24 20:10:20 -07:00
unstructured_test.go Use zaptest logger for our TestLogger (#89) 2018-09-25 21:40:20 -07:00
verify.go 🦆 Duck Typing - add a ConformsToType helper (#220) 2019-01-09 19:58:42 -08:00
verify_test.go 🦆 Duck Typing - add a ConformsToType helper (#220) 2019-01-09 19:58:42 -08:00