Releases: vmware-labs/reconciler-runtime
v0.19.0
This release contains a few new features, a deprecation and a few dependency updates.
Features
- Allow resources to contain unexported fields
ChildSetReconciler
lists children exactly once⚠️ potentially breaking:ListOptions
is required whenSkipOwnerReference
is true. If you are operating in the same namespace but skip owner references, this may break your kit. The reconciler validation will fail fast and report the issue. You will have to setListOptions
going forward.
Deprecations
- SafeDeployDiff is deprecated and scheduled to be removed in the next version. Use reconcilers.IgnoreAllUnexported instead.
What's Changed
- Allow resources to contain unexported fields by @scothis in #487
- Bump golang.org/x/net from 0.21.0 to 0.22.0 by @dependabot in #491
- Bump dies.dev from 0.10.0 to 0.10.1 by @dependabot in #490
- Bump dies.dev/diegen from 0.10.0 to 0.10.1 in /hack by @dependabot in #492
- Require ListOptions when SkipOwnerReference is true by @scothis in #493
- List children exactly once for ChildSetReconciler by @scothis in #494
Full Changelog: v0.18.0...v0.19.0
v0.18.0
This release contains a few new features and a few dependency updates.
Features
- Handle pointer items in ObjectList with ChildReconciler
- Support Kubernetes 1.29
What's Changed
- Support Kubernetes 1.29 by @mamachanko in #476
- Bump golang.org/x/net from 0.20.0 to 0.21.0 by @dependabot in #477
- Bump sigs.k8s.io/controller-runtime from 0.17.0 to 0.17.1 by @dependabot in #478
- Handle pointer items in ObjectList with ChildReconciler by @scothis in #480
- Bump the kubernetes group with 3 updates by @dependabot in #482
- Bump sigs.k8s.io/controller-runtime from 0.17.1 to 0.17.2 by @dependabot in #483
Full Changelog: v0.17.0...v0.18.0
v0.17.0
This release contains a single new feature and a few dependency updates.
Features
CastResource
updates the original cast resource even on reconciliation error
What's Changed
- Bump golang.org/x/net from 0.19.0 to 0.20.0 by @dependabot in #467
- Bump sigs.k8s.io/controller-tools from 0.13.0 to 0.14.0 in /hack by @dependabot in #468
- Bump github.com/evanphx/json-patch/v5 from 5.7.0 to 5.8.0 by @dependabot in #469
- Bump github.com/evanphx/json-patch/v5 from 5.8.0 to 5.8.1 by @dependabot in #471
- Update original cast resource even on reconciliation error by @LittleBaiBai in #474
- Bump github.com/evanphx/json-patch/v5 from 5.8.1 to 5.9.0 by @dependabot in #475
New Contributors
- @LittleBaiBai made their first contribution in #474
Full Changelog: v0.16.0...v0.17.0
v0.16.0
This release contains new features, improvements to docs and upgrades of dependencies.
Features
ChildReconciler#MergeBeforeUpdate
is validatedChildSetReconciler#DesiredChildren
provides access to known children- Test
SubReconcilers
with duck-typed resources
What's Changed
- Bump golang.org/x/net from 0.14.0 to 0.17.0 in /hack by @dependabot in #443
- Clarify ChildSetReconciler doc by @scothis in #444
- Remove generic bits from types that are not generic by @scothis in #448
- Bump sigs.k8s.io/yaml from 1.3.0 to 1.4.0 by @dependabot in #449
- validate MergeBeforeUpdate in ChildReconciler by @squeedee in #451
- Bump github.com/fatih/color from 1.15.0 to 1.16.0 by @dependabot in #453
- Enable testing SubReconcilers with duck typed resources by @scothis in #454
- Bump golang.org/x/net from 0.17.0 to 0.18.0 by @dependabot in #457
- Allow access to known children in ChildSetReconciler#DesiredChildren by @scothis in #458
- Current maintainers review dependabot PRs by @mamachanko in #464
- Bump actions/setup-go from 4 to 5 by @dependabot in #463
- Bump sigs.k8s.io/controller-runtime from 0.16.0 to 0.16.3 by @dependabot in #445
- Bump golang.org/x/net from 0.18.0 to 0.19.0 by @dependabot in #461
- Bump the kubernetes group with 2 updates by @dependabot in #460
- Added a KB style document about RestMapper by @squeedee in #462
- Add MAINTAINERS.md by @mamachanko in #465
Full Changelog: v0.15.1...v0.16.0
v0.15.1
What's Changed
- Bump golang.org/x/net from 0.15.0 to 0.16.0 by @dependabot in #439
- Bump golang.org/x/net from 0.16.0 to 0.17.0 by @dependabot in #440
- Bump github.com/google/go-cmp from 0.5.9 to 0.6.0 by @dependabot in #441
- Switch ResourceManager update cache to JSON Patch by @scothis in #442
Full Changelog: v0.15.0...v0.15.1
v0.15.0
Breaking Changes
- Managed resources that do not need to be updated are now tracked as needed. Tests may see a new
ExpectTrack
item. In particular when aChildReconciler
is used withSkipOwnerReferences
turned on.
Current Deprecations
Backwards support may be removed in a future release, users are encouraged to migrate.
- status
InitializeConditions()
is deprecated in favor ofInitializeConditions(context.Context)
. ConditionSet#Manage
is deprecated in favor ofConditionSet#ManageWithContext
.HaltSubReconcilers
is deprecated in favor ofErrHaltSubReconcilers
.
Highlights
- New flow control SubReconcilers IfThen, While, TryCatch, and OverrideSetup #414
- Refine test assertion output including colorized diffs #423
- Allow ChildReconciler/ChildSetReconciler to reflect invalid API errors to status #418
What's Changed
- Bump sigs.k8s.io/controller-tools from 0.12.1 to 0.13.0 in /hack by @dependabot in #409
- Small improvements to the README by @mamachanko in #410
- Fix go syntax in README by @mamachanko in #411
- Fix concatenated log context in Sequence by @xtreme-conor-nosal in #412
- Bump sigs.k8s.io/controller-runtime from 0.15.1 to 0.16.0 by @dependabot in #413
- Switch to testr package by @scothis in #416
- avoid implying that the error can be anything but nil by @squeedee in #417
- Allow ChildReconciler to reflect invalid api errors by @scothis in #418
- Extend test GenerateName support to Unstructureds by @scothis in #420
- Flow control SubReconcilers by @scothis in #414
- Track managed resources when update is skipped by @scothis in #421
- Bump actions/checkout from 3 to 4 by @dependabot in #427
- Refine test assertion output by @scothis in #423
- Capture resourceType GVK in logs for duck types by @scothis in #430
- Allow errors to be quiet by @scothis in #429
- Bump golang.org/x/net from 0.14.0 to 0.15.0 by @dependabot in #431
- Bump github.com/evanphx/json-patch/v5 from 5.6.0 to 5.7.0 by @dependabot in #433
- Streamline finalizer patching by @scothis in #434
Full Changelog: v0.14.0...v0.15.0
v0.14.0
Breaking changes
- Kubernetes 1.28 types and client-go are in use. Any upstream breaking changes are reflected here.
- status
InitiazeConditions()
is deprecated in favor ofInitializeConditions(context.Context)
. Support may be removed in a future release, users are encuraged to migrate. ConditionSet#Manage
is deprecated in favor ofConditionSet#ManageWithContext
. Support may be removed in a future release, users are encuraged to migrate.
Highlights
Duck typed resources may now be used directly with the client and reconciled. These are structured types that represent a subset of many arbitrary resources. The APIVersion and Kind fields must be set explicitly on the object and the type must not be registered with the scheme. See Reconcilers in the readme for a discussion of the different types of resources that can be used and the tradeoff for each type.
Pinned reconcile time. Testing reconciler that write the current time back to the resource can be difficult to test because the result is ephemeral by nature. Each reconcile request now captures the current time at the start of the request and makes that value available to nested reconcilers for use instead of time.Now
. This value can also be defined in individual test cases so that the reconciler output is deterministic. See Time in the readme for an overview of the new APIs.
What's Changed
- Duck type clients and reconcilers by @scothis in #402
- Bump gomodules.xyz/jsonpatch/v2 from 2.3.0 to 2.4.0 by @dependabot in #403
- Kubernetes 1.28 support by @scothis in #404
Full Changelog: v0.13.0...v0.14.0
v0.13.0
No new breaking changes or deprecations.
Highlights
ChildSetReconciler
allows for zero-to-many child resources to be managed from a single reconciler. Under the hood, it dynamically composes a ChildReconciler
for each desired and actual child resource, correlated by a stable identifier.
What's Changed
- Handle nil actual resource in resource manager by @scothis in #378
- Update README.md to explain the watch behaviour of childResource by @squeedee in #380
- APIGroup != APIVersion by @squeedee in #386
- Bump golang.org/x/net from 0.10.0 to 0.11.0 by @dependabot in #381
- Bump k8s.io/client-go from 0.27.2 to 0.27.3 by @dependabot in #383
- Use github.com/evanphx/json-patch/v5 for patching by @scothis in #388
- Preserve results when subreconcilers halt by @xtreme-conor-nosal in #390
- Bump golang.org/x/net from 0.11.0 to 0.12.0 by @dependabot in #391
- Bump sigs.k8s.io/controller-tools from 0.12.0 to 0.12.1 in /hack by @dependabot in #392
- Bump k8s.io/client-go from 0.27.3 to 0.27.4 by @dependabot in #395
- ChildSetReconciler as a dynamic composition of ChildReconcilers by @scothis and @LittleBaiBai in #396
- Bump golang.org/x/net from 0.12.0 to 0.13.0 by @dependabot in #398
- Respect desired child's controlling owner reference by @scothis in #397
- Decompose reconcilers.go by @scothis in #399
- Bump sigs.k8s.io/controller-runtime from 0.15.0 to 0.15.1 by @dependabot in #401
- Bump golang.org/x/net from 0.13.0 to 0.14.0 by @dependabot in #400
New Contributors
- @squeedee made their first contribution in #380
- @xtreme-conor-nosal made their first contribution in #390
- @LittleBaiBai made their first contribution in #396
Full Changelog: v0.12.0...v0.13.0
v0.12.0
Breaking Changes
There are a lot of minor breaking changes that accumulate in this release.
- all previously deprecated APIs have been removed
- breaking changes introduced upstream in K8s 1.27 and controller-runtime 0.15 are present
- generics are used to make reconcilers type-safe and eliminate reflection for method fields. The type fields are now optional unless the generic type is
Unstructured
, in which case theapiVersion
/kind
fields must be defined explicitly. SyncReconciler.Sync
is split intoSync
andSyncWithResult
that vary on the return arguments, same for theFinalize
method.ChildReconciler.ReflectChildStatusOnParent
now requires a context- the
Tracker
has a wholly new interface and now supports tracking by label selector. Indirect use of the tracker preserves compatibility.
What's Changed
- Bump golang.org/x/net from 0.3.1-0.20221206200815-1e63c2f08a10 to 0.7.0 by @dependabot in #338
- Bump sigs.k8s.io/controller-runtime from 0.14.4 to 0.14.5 by @dependabot in #342
- Bump k8s.io/api from 0.26.1 to 0.26.2 by @dependabot in #341
- Bump golang.org/x/net from 0.7.0 to 0.8.0 by @dependabot in #343
- Bump actions/setup-go from 3 to 4 by @dependabot in #344
- Bump k8s.io/client-go from 0.26.2 to 0.26.3 by @dependabot in #345
- Bump sigs.k8s.io/controller-runtime from 0.14.5 to 0.14.6 by @dependabot in #348
- Apply go 1.18 generics across reconciler-runtime by @scothis in #349
- Bump golang.org/x/net from 0.8.0 to 0.9.0 by @dependabot in #350
- Allow ResourceReconciler to skip status updates by @scothis in #360
- Restore support in ChildReconciler for unstructured resources by @scothis in #362
- Allow ChildReconciler to stash in ReflectChildStatusOnParent by @scothis in #363
- Bump sigs.k8s.io/controller-tools from 0.11.3 to 0.11.4 in /hack by @dependabot in #361
- Use CI to assert no drift in generated files by @scothis in #364
- Clarify doc for ChildReconciler#ReflectChildStatusOnParent by @scothis in #365
- Bump sigs.k8s.io/controller-tools from 0.11.4 to 0.12.0 in /hack by @dependabot in #366
- Bump golang.org/x/net from 0.9.0 to 0.10.0 by @dependabot in #368
- Track resources with a label selector by @scothis in #367
- Track controller-runtime 0.15 development by @scothis in #356
- Bump sigs.k8s.io/controller-runtime from 0.15.0-alpha.0 to 0.15.0-alpha.1 by @dependabot in #372
- Bump k8s.io/client-go from 0.27.1 to 0.27.2 by @dependabot in #371
- Update controller-runtime to 0.15.0 by @scothis in #374
Full Changelog: v0.11.1...v0.12.0
v0.12.0-alpha.0
This is a pre-release to track controller-runtime's v0.15.0-alpha.0 tag. There will be additional changes before the 0.12 reconciler-runtime release.
Breaking Changes
There are a lot of minor breaking changes that accumulate in this release.
- all previously deprecated APIs have been removed
- breaking changes introduced upstream in K8s 1.27 and controller-runtime 0.15 are present
- generics are used to make reconcilers type-safe and eliminate reflection for method fields. The type fields are now optional unless the generic type is unstructured, in which case the apiVersion/kind data must be defined explicitly.
- SyncReconciler.Sync is split into Sync and SyncWithResult that vary on the return arguments, same for the Finalize method.
- ChildReconciler.ReflectChildStatusOnParent now requires a context
- the Tracker has a wholly new interface and now supports tracking by label selector. Indirect use of the tracker preserves compatibility.
What's Changed
- Bump golang.org/x/net from 0.3.1-0.20221206200815-1e63c2f08a10 to 0.7.0 by @dependabot in #338
- Bump sigs.k8s.io/controller-runtime from 0.14.4 to 0.14.5 by @dependabot in #342
- Bump k8s.io/api from 0.26.1 to 0.26.2 by @dependabot in #341
- Bump golang.org/x/net from 0.7.0 to 0.8.0 by @dependabot in #343
- Bump actions/setup-go from 3 to 4 by @dependabot in #344
- Bump k8s.io/client-go from 0.26.2 to 0.26.3 by @dependabot in #345
- Bump sigs.k8s.io/controller-runtime from 0.14.5 to 0.14.6 by @dependabot in #348
- Apply go 1.18 generics across reconciler-runtime by @scothis in #349
- Bump golang.org/x/net from 0.8.0 to 0.9.0 by @dependabot in #350
- Allow ResourceReconciler to skip status updates by @scothis in #360
- Restore support in ChildReconciler for unstructured resources by @scothis in #362
- Allow ChildReconciler to stash in ReflectChildStatusOnParent by @scothis in #363
- Bump sigs.k8s.io/controller-tools from 0.11.3 to 0.11.4 in /hack by @dependabot in #361
- Use CI to assert no drift in generated files by @scothis in #364
- Clarify doc for ChildReconciler#ReflectChildStatusOnParent by @scothis in #365
- Bump sigs.k8s.io/controller-tools from 0.11.4 to 0.12.0 in /hack by @dependabot in #366
- Bump golang.org/x/net from 0.9.0 to 0.10.0 by @dependabot in #368
- Track resources with a label selector by @scothis in #367
- Track controller-runtime 0.15 development by @scothis in #356
Full Changelog: v0.11.1...v0.12.0-alpha.0