@@ -29,6 +29,7 @@ const (
2929 rs wellKnownControllerKind = "ReplicaSet"
3030 rc wellKnownControllerKind = "ReplicationController"
3131 sts wellKnownControllerKind = "StatefulSet"
32+ ro wellKnownControllerKind = "Rollout"
3233)
3334
3435// TargetController abstract a scalable controller
@@ -53,7 +54,7 @@ func NewTargetController(c client.Interface, ref *autoscalingv1.CrossVersionObje
5354 kind := obj .GetKind ()
5455
5556 switch wellKnownControllerKind (kind ) {
56- case cj , ds , deploy , job , rs , rc , sts :
57+ case cj , ds , deploy , job , rs , rc , sts , ro :
5758 case node :
5859 // Some pods specify nodes as their owners,
5960 // but they aren't valid controllers that
@@ -204,7 +205,7 @@ func (tc *TargetController) ReplicasCount() (int64, error) {
204205
205206func genericControllerSpecPath (kind string , fields []string ) ([]string , error ) {
206207 switch wellKnownControllerKind (kind ) {
207- case ds , deploy , job , rs , rc , sts :
208+ case ds , deploy , job , rs , rc , sts , ro :
208209 // Same default fields.
209210 case cj :
210211 prefix := []string {
0 commit comments