File tree Expand file tree Collapse file tree 1 file changed +18
-1
lines changed Expand file tree Collapse file tree 1 file changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,11 @@ limitations under the License.
16
16
17
17
package controller
18
18
19
- import "net/http"
19
+ import (
20
+ "net/http"
21
+
22
+ "k8s.io/controller-manager/pkg/healthz"
23
+ )
20
24
21
25
// Interface defines the base of a controller managed by a controller manager
22
26
type Interface interface {
@@ -36,3 +40,16 @@ type Debuggable interface {
36
40
// The handler will be accessible at "/debug/controllers/{controllerName}/".
37
41
DebuggingHandler () http.Handler
38
42
}
43
+
44
+ // HealthCheckable defines a controller that allows the controller manager
45
+ // to include it in the health checks.
46
+ //
47
+ // If a controller implements HealthCheckable, and the returned check
48
+ // is not nil, the controller manager can expose the check to the
49
+ // /healthz endpoint.
50
+ type HealthCheckable interface {
51
+ // HealthChecker returns a UnnamedHealthChecker that the controller manager
52
+ // can choose to mount on the /healthz endpoint, or nil if no custom
53
+ // health check is desired.
54
+ HealthChecker () healthz.UnnamedHealthChecker
55
+ }
You can’t perform that action at this time.
0 commit comments