@@ -24,24 +24,20 @@ import (
2424 "k8s.io/apimachinery/pkg/runtime"
2525 "k8s.io/apimachinery/pkg/runtime/serializer"
2626 utilruntime "k8s.io/apimachinery/pkg/util/runtime"
27- "sigs.k8s.io/controller-runtime/pkg/config/v1alpha1" //nolint:staticcheck
27+ "sigs.k8s.io/controller-runtime/pkg/config/v1alpha1"
2828)
2929
3030// ControllerManagerConfiguration defines the functions necessary to parse a config file
3131// and to configure the Options struct for the ctrl.Manager.
32- //
33- // Deprecated: This package has been deprecated and will be removed in a future release.
3432type ControllerManagerConfiguration interface {
3533 runtime.Object
3634
3735 // Complete returns the versioned configuration
38- Complete () (v1alpha1.ControllerManagerConfigurationSpec , error ) //nolint:staticcheck
36+ Complete () (v1alpha1.ControllerManagerConfigurationSpec , error )
3937}
4038
4139// DeferredFileLoader is used to configure the decoder for loading controller
4240// runtime component config types.
43- //
44- // Deprecated: This package has been deprecated and will be removed in a future release.
4541type DeferredFileLoader struct {
4642 ControllerManagerConfiguration
4743 path string
@@ -56,8 +52,6 @@ type DeferredFileLoader struct {
5652// Defaults:
5753// * Path: "./config.yaml"
5854// * Kind: GenericControllerManagerConfiguration
59- //
60- // Deprecated: This package has been deprecated and will be removed in a future release.
6155func File () * DeferredFileLoader {
6256 scheme := runtime .NewScheme ()
6357 utilruntime .Must (v1alpha1 .AddToScheme (scheme ))
@@ -69,8 +63,6 @@ func File() *DeferredFileLoader {
6963}
7064
7165// Complete will use sync.Once to set the scheme.
72- //
73- // Deprecated: This package has been deprecated and will be removed in a future release.
7466func (d * DeferredFileLoader ) Complete () (v1alpha1.ControllerManagerConfigurationSpec , error ) {
7567 d .once .Do (d .loadFile )
7668 if d .err != nil {
@@ -79,33 +71,25 @@ func (d *DeferredFileLoader) Complete() (v1alpha1.ControllerManagerConfiguration
7971 return d .ControllerManagerConfiguration .Complete ()
8072}
8173
82- // AtPath will set the path to load the file for the decoder
83- //
84- // Deprecated: This package has been deprecated and will be removed in a future release.
74+ // AtPath will set the path to load the file for the decoder.
8575func (d * DeferredFileLoader ) AtPath (path string ) * DeferredFileLoader {
8676 d .path = path
8777 return d
8878}
8979
9080// OfKind will set the type to be used for decoding the file into.
91- //
92- // Deprecated: This package has been deprecated and will be removed in a future release.
9381func (d * DeferredFileLoader ) OfKind (obj ControllerManagerConfiguration ) * DeferredFileLoader {
9482 d .ControllerManagerConfiguration = obj
9583 return d
9684}
9785
9886// InjectScheme will configure the scheme to be used for decoding the file.
99- //
100- // Deprecated: This package has been deprecated and will be removed in a future release.
10187func (d * DeferredFileLoader ) InjectScheme (scheme * runtime.Scheme ) error {
10288 d .scheme = scheme
10389 return nil
10490}
10591
10692// loadFile is used from the mutex.Once to load the file.
107- //
108- // Deprecated: This package has been deprecated and will be removed in a future release.
10993func (d * DeferredFileLoader ) loadFile () {
11094 if d .scheme == nil {
11195 d .err = fmt .Errorf ("scheme not supplied to controller configuration loader" )
0 commit comments