Skip to content

Commit

Permalink
edit in controllerv2.go
Browse files Browse the repository at this point in the history
  • Loading branch information
Rahul-Kumar-prog committed Aug 2, 2023
1 parent 67271f4 commit a407f84
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions control-plane/pkg/reconciler/channel/v2/controllerv2.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,18 +112,14 @@ func NewController(ctx context.Context, watcher configmap.Watcher, configs *conf
logger.Fatal("Failed to create prober", zap.Error(err))
}

Check warning on line 113 in control-plane/pkg/reconciler/channel/v2/controllerv2.go

View check run for this annotation

Codecov / codecov/patch

control-plane/pkg/reconciler/channel/v2/controllerv2.go#L112-L113

Added lines #L112 - L113 were not covered by tests

globalResync := func(_ interface{}) {
impl.GlobalResync(channelInformer.Informer())
}

rotateCACerts := func(obj interface{}) {
newCerts, err := reconciler.getCaCerts()
if err != nil && (features.IsPermissiveTransportEncryption() || features.IsStrictTransportEncryption()) {
// We only need to warn here as the broker won't reconcile properly without the proper certs because the prober won't succeed
logger.Warn("Failed to get new CA certs while rotating CA certs when at least one address uses TLS", zap.Error(err))
}
reconciler.Prober.RotateRootCaCerts(&newCerts)
globalResync(obj)
consumergroup.Enqueue("kafkachannel", impl.EnqueueKey)

Check warning on line 122 in control-plane/pkg/reconciler/channel/v2/controllerv2.go

View check run for this annotation

Codecov / codecov/patch

control-plane/pkg/reconciler/channel/v2/controllerv2.go#L116-L122

Added lines #L116 - L122 were not covered by tests
}
reconciler.Tracker = impl.Tracker
secretinformer.Get(ctx).Informer().AddEventHandler(controller.HandleAll(reconciler.Tracker.OnChanged))
Expand Down

0 comments on commit a407f84

Please sign in to comment.