Skip to content

Commit

Permalink
remove health checker
Browse files Browse the repository at this point in the history
  • Loading branch information
maleck13 committed Mar 11, 2024
1 parent e8504b6 commit cd1a31a
Show file tree
Hide file tree
Showing 22 changed files with 36 additions and 1,539 deletions.
9 changes: 0 additions & 9 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,3 @@ resources:
kind: DNSRecord
path: github.com/kuadrant/dns-operator/api/v1alpha1
version: v1alpha1
- api:
crdVersion: v1
namespaced: true
controller: true
domain: kuadrant.io
kind: DNSHealthCheckProbe
path: github.com/kuadrant/dns-operator/api/v1alpha1
version: v1alpha1
version: "3"
88 changes: 0 additions & 88 deletions api/v1alpha1/dnshealthcheckprobe_types.go

This file was deleted.

56 changes: 0 additions & 56 deletions api/v1alpha1/health_types.go

This file was deleted.

160 changes: 0 additions & 160 deletions api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

25 changes: 1 addition & 24 deletions cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ package main
import (
"flag"
"os"
"time"

"k8s.io/apimachinery/pkg/runtime"
utilruntime "k8s.io/apimachinery/pkg/util/runtime"
Expand All @@ -33,7 +32,6 @@ import (

"github.com/kuadrant/dns-operator/api/v1alpha1"
"github.com/kuadrant/dns-operator/internal/controller"
"github.com/kuadrant/dns-operator/internal/health"
"github.com/kuadrant/dns-operator/internal/provider"
_ "github.com/kuadrant/dns-operator/internal/provider/aws"
_ "github.com/kuadrant/dns-operator/internal/provider/google"
Expand Down Expand Up @@ -84,19 +82,6 @@ func main() {

providerFactory := provider.NewFactory(mgr.GetClient())

healthMonitor := health.NewMonitor()
healthCheckQueue := health.NewRequestQueue(time.Second * 5)

if err := mgr.Add(healthMonitor); err != nil {
setupLog.Error(err, "unable to start health monitor")
os.Exit(1)
}

if err := mgr.Add(healthCheckQueue); err != nil {
setupLog.Error(err, "unable to start health check queue")
os.Exit(1)
}

if err = (&controller.ManagedZoneReconciler{
Client: mgr.GetClient(),
Scheme: mgr.GetScheme(),
Expand All @@ -113,15 +98,7 @@ func main() {
setupLog.Error(err, "unable to create controller", "controller", "DNSRecord")
os.Exit(1)
}
if err = (&controller.DNSHealthCheckProbeReconciler{
Client: mgr.GetClient(),
Scheme: mgr.GetScheme(),
HealthMonitor: healthMonitor,
Queue: healthCheckQueue,
}).SetupWithManager(mgr); err != nil {
setupLog.Error(err, "unable to create controller", "controller", "DNSHealthCheckProbe")
os.Exit(1)
}

//+kubebuilder:scaffold:builder

if err := mgr.AddHealthzCheck("healthz", healthz.Ping); err != nil {
Expand Down
Loading

0 comments on commit cd1a31a

Please sign in to comment.