From c4a1ab42e3023eaabca7492878f8c6cc908d8090 Mon Sep 17 00:00:00 2001 From: mqliang Date: Sun, 31 Jan 2016 21:59:58 +0800 Subject: [PATCH] Move MinReadySeconds out of RollingUpdateDeployment --- docs/user-guide/deployments.md | 2 +- pkg/apis/extensions/types.generated.go | 1094 ++++++++--------- pkg/apis/extensions/types.go | 10 +- pkg/apis/extensions/v1beta1/conversion.go | 4 +- .../v1beta1/conversion_generated.go | 4 +- .../extensions/v1beta1/deep_copy_generated.go | 2 +- .../extensions/v1beta1/types.generated.go | 1060 ++++++++-------- pkg/apis/extensions/v1beta1/types.go | 10 +- .../v1beta1/types_swagger_doc_generated.go | 8 +- pkg/apis/extensions/validation/validation.go | 2 +- .../deployment/deployment_controller.go | 7 +- pkg/kubectl/describe.go | 3 +- test/e2e/deployment.go | 6 +- 13 files changed, 1105 insertions(+), 1107 deletions(-) diff --git a/docs/user-guide/deployments.md b/docs/user-guide/deployments.md index 18782011a8b..d3f4dbac22c 100644 --- a/docs/user-guide/deployments.md +++ b/docs/user-guide/deployments.md @@ -399,7 +399,7 @@ at any time during the update is at most 130% of desired pods. ##### Min Ready Seconds -`.spec.strategy.rollingUpdate.minReadySeconds` is an optional field that specifies the +`.spec.minReadySeconds` is an optional field that specifies the minimum number of seconds for which a newly created pod should be ready without any of its containers crashing, for it to be considered available. This defaults to 0 (the pod will be considered available as soon as it is ready). diff --git a/pkg/apis/extensions/types.generated.go b/pkg/apis/extensions/types.generated.go index 3b86b8ca347..725e9cb4ff3 100644 --- a/pkg/apis/extensions/types.generated.go +++ b/pkg/apis/extensions/types.generated.go @@ -5426,19 +5426,20 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep453 := !z.EncBinary() yy2arr453 := z.EncBasicHandle().StructToArray - var yyq453 [8]bool + var yyq453 [9]bool _, _, _ = yysep453, yyq453, yy2arr453 const yyr453 bool = false yyq453[0] = x.Replicas != 0 yyq453[1] = len(x.Selector) != 0 yyq453[3] = true - yyq453[4] = x.RevisionHistoryLimit != nil - yyq453[5] = x.UniqueLabelKey != "" - yyq453[6] = x.Paused != false - yyq453[7] = x.RollbackTo != nil + yyq453[4] = x.MinReadySeconds != 0 + yyq453[5] = x.RevisionHistoryLimit != nil + yyq453[6] = x.UniqueLabelKey != "" + yyq453[7] = x.Paused != false + yyq453[8] = x.RollbackTo != nil var yynn453 int if yyr453 || yy2arr453 { - r.EncodeArrayStart(8) + r.EncodeArrayStart(9) } else { yynn453 = 1 for _, b := range yyq453 { @@ -5538,60 +5539,60 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { if yyr453 || yy2arr453 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq453[4] { - if x.RevisionHistoryLimit == nil { - r.EncodeNil() + yym467 := z.EncBinary() + _ = yym467 + if false { } else { - yy467 := *x.RevisionHistoryLimit - yym468 := z.EncBinary() - _ = yym468 - if false { - } else { - r.EncodeInt(int64(yy467)) - } + r.EncodeInt(int64(x.MinReadySeconds)) } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { if yyq453[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) + r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RevisionHistoryLimit == nil { - r.EncodeNil() + yym468 := z.EncBinary() + _ = yym468 + if false { } else { - yy469 := *x.RevisionHistoryLimit - yym470 := z.EncBinary() - _ = yym470 - if false { - } else { - r.EncodeInt(int64(yy469)) - } + r.EncodeInt(int64(x.MinReadySeconds)) } } } if yyr453 || yy2arr453 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq453[5] { - yym472 := z.EncBinary() - _ = yym472 - if false { + if x.RevisionHistoryLimit == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UniqueLabelKey)) + yy470 := *x.RevisionHistoryLimit + yym471 := z.EncBinary() + _ = yym471 + if false { + } else { + r.EncodeInt(int64(yy470)) + } } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { if yyq453[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uniqueLabelKey")) + r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym473 := z.EncBinary() - _ = yym473 - if false { + if x.RevisionHistoryLimit == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UniqueLabelKey)) + yy472 := *x.RevisionHistoryLimit + yym473 := z.EncBinary() + _ = yym473 + if false { + } else { + r.EncodeInt(int64(yy472)) + } } } } @@ -5601,6 +5602,31 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { yym475 := z.EncBinary() _ = yym475 if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.UniqueLabelKey)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq453[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("uniqueLabelKey")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym476 := z.EncBinary() + _ = yym476 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.UniqueLabelKey)) + } + } + } + if yyr453 || yy2arr453 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq453[7] { + yym478 := z.EncBinary() + _ = yym478 + if false { } else { r.EncodeBool(bool(x.Paused)) } @@ -5608,12 +5634,12 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq453[6] { + if yyq453[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("paused")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym476 := z.EncBinary() - _ = yym476 + yym479 := z.EncBinary() + _ = yym479 if false { } else { r.EncodeBool(bool(x.Paused)) @@ -5622,7 +5648,7 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { } if yyr453 || yy2arr453 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[7] { + if yyq453[8] { if x.RollbackTo == nil { r.EncodeNil() } else { @@ -5632,7 +5658,7 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq453[7] { + if yyq453[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -5656,25 +5682,25 @@ func (x *DeploymentSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym478 := z.DecBinary() - _ = yym478 + yym481 := z.DecBinary() + _ = yym481 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct479 := r.ContainerType() - if yyct479 == codecSelferValueTypeMap1234 { - yyl479 := r.ReadMapStart() - if yyl479 == 0 { + yyct482 := r.ContainerType() + if yyct482 == codecSelferValueTypeMap1234 { + yyl482 := r.ReadMapStart() + if yyl482 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl479, d) + x.codecDecodeSelfFromMap(yyl482, d) } - } else if yyct479 == codecSelferValueTypeArray1234 { - yyl479 := r.ReadArrayStart() - if yyl479 == 0 { + } else if yyct482 == codecSelferValueTypeArray1234 { + yyl482 := r.ReadArrayStart() + if yyl482 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl479, d) + x.codecDecodeSelfFromArray(yyl482, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -5686,12 +5712,12 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys480Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys480Slc - var yyhl480 bool = l >= 0 - for yyj480 := 0; ; yyj480++ { - if yyhl480 { - if yyj480 >= l { + var yys483Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys483Slc + var yyhl483 bool = l >= 0 + for yyj483 := 0; ; yyj483++ { + if yyhl483 { + if yyj483 >= l { break } } else { @@ -5700,10 +5726,10 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys480Slc = r.DecodeBytes(yys480Slc, true, true) - yys480 := string(yys480Slc) + yys483Slc = r.DecodeBytes(yys483Slc, true, true) + yys483 := string(yys483Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys480 { + switch yys483 { case "replicas": if r.TryDecodeAsNil() { x.Replicas = 0 @@ -5714,27 +5740,33 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv482 := &x.Selector - yym483 := z.DecBinary() - _ = yym483 + yyv485 := &x.Selector + yym486 := z.DecBinary() + _ = yym486 if false { } else { - z.F.DecMapStringStringX(yyv482, false, d) + z.F.DecMapStringStringX(yyv485, false, d) } } case "template": if r.TryDecodeAsNil() { x.Template = pkg2_api.PodTemplateSpec{} } else { - yyv484 := &x.Template - yyv484.CodecDecodeSelf(d) + yyv487 := &x.Template + yyv487.CodecDecodeSelf(d) } case "strategy": if r.TryDecodeAsNil() { x.Strategy = DeploymentStrategy{} } else { - yyv485 := &x.Strategy - yyv485.CodecDecodeSelf(d) + yyv488 := &x.Strategy + yyv488.CodecDecodeSelf(d) + } + case "minReadySeconds": + if r.TryDecodeAsNil() { + x.MinReadySeconds = 0 + } else { + x.MinReadySeconds = int(r.DecodeInt(codecSelferBitsize1234)) } case "revisionHistoryLimit": if r.TryDecodeAsNil() { @@ -5745,8 +5777,8 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.RevisionHistoryLimit == nil { x.RevisionHistoryLimit = new(int) } - yym487 := z.DecBinary() - _ = yym487 + yym491 := z.DecBinary() + _ = yym491 if false { } else { *((*int)(x.RevisionHistoryLimit)) = int(r.DecodeInt(codecSelferBitsize1234)) @@ -5776,9 +5808,9 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.RollbackTo.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys480) - } // end switch yys480 - } // end for yyj480 + z.DecStructFieldNotFound(-1, yys483) + } // end switch yys483 + } // end for yyj483 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -5786,16 +5818,16 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj491 int - var yyb491 bool - var yyhl491 bool = l >= 0 - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + var yyj495 int + var yyb495 bool + var yyhl495 bool = l >= 0 + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5805,13 +5837,13 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } else { x.Replicas = int(r.DecodeInt(codecSelferBitsize1234)) } - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5819,21 +5851,21 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv493 := &x.Selector - yym494 := z.DecBinary() - _ = yym494 + yyv497 := &x.Selector + yym498 := z.DecBinary() + _ = yym498 if false { } else { - z.F.DecMapStringStringX(yyv493, false, d) + z.F.DecMapStringStringX(yyv497, false, d) } } - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5841,16 +5873,16 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Template = pkg2_api.PodTemplateSpec{} } else { - yyv495 := &x.Template - yyv495.CodecDecodeSelf(d) + yyv499 := &x.Template + yyv499.CodecDecodeSelf(d) } - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5858,16 +5890,32 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Strategy = DeploymentStrategy{} } else { - yyv496 := &x.Strategy - yyv496.CodecDecodeSelf(d) + yyv500 := &x.Strategy + yyv500.CodecDecodeSelf(d) } - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MinReadySeconds = 0 + } else { + x.MinReadySeconds = int(r.DecodeInt(codecSelferBitsize1234)) + } + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l + } else { + yyb495 = r.CheckBreak() + } + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5880,20 +5928,20 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.RevisionHistoryLimit == nil { x.RevisionHistoryLimit = new(int) } - yym498 := z.DecBinary() - _ = yym498 + yym503 := z.DecBinary() + _ = yym503 if false { } else { *((*int)(x.RevisionHistoryLimit)) = int(r.DecodeInt(codecSelferBitsize1234)) } } - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5903,13 +5951,13 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } else { x.UniqueLabelKey = string(r.DecodeString()) } - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5919,13 +5967,13 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } else { x.Paused = bool(r.DecodeBool()) } - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5941,17 +5989,17 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.RollbackTo.CodecDecodeSelf(d) } for { - yyj491++ - if yyhl491 { - yyb491 = yyj491 > l + yyj495++ + if yyhl495 { + yyb495 = yyj495 > l } else { - yyb491 = r.CheckBreak() + yyb495 = r.CheckBreak() } - if yyb491 { + if yyb495 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj491-1, "") + z.DecStructFieldNotFound(yyj495-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -5963,37 +6011,37 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym502 := z.EncBinary() - _ = yym502 + yym507 := z.EncBinary() + _ = yym507 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep503 := !z.EncBinary() - yy2arr503 := z.EncBasicHandle().StructToArray - var yyq503 [5]bool - _, _, _ = yysep503, yyq503, yy2arr503 - const yyr503 bool = false - yyq503[0] = x.Kind != "" - yyq503[1] = x.APIVersion != "" - yyq503[3] = len(x.UpdatedAnnotations) != 0 - var yynn503 int - if yyr503 || yy2arr503 { + yysep508 := !z.EncBinary() + yy2arr508 := z.EncBasicHandle().StructToArray + var yyq508 [5]bool + _, _, _ = yysep508, yyq508, yy2arr508 + const yyr508 bool = false + yyq508[0] = x.Kind != "" + yyq508[1] = x.APIVersion != "" + yyq508[3] = len(x.UpdatedAnnotations) != 0 + var yynn508 int + if yyr508 || yy2arr508 { r.EncodeArrayStart(5) } else { - yynn503 = 2 - for _, b := range yyq503 { + yynn508 = 2 + for _, b := range yyq508 { if b { - yynn503++ + yynn508++ } } - r.EncodeMapStart(yynn503) - yynn503 = 0 + r.EncodeMapStart(yynn508) + yynn508 = 0 } - if yyr503 || yy2arr503 { + if yyr508 || yy2arr508 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq503[0] { - yym505 := z.EncBinary() - _ = yym505 + if yyq508[0] { + yym510 := z.EncBinary() + _ = yym510 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -6002,23 +6050,23 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq503[0] { + if yyq508[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym506 := z.EncBinary() - _ = yym506 + yym511 := z.EncBinary() + _ = yym511 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr503 || yy2arr503 { + if yyr508 || yy2arr508 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq503[1] { - yym508 := z.EncBinary() - _ = yym508 + if yyq508[1] { + yym513 := z.EncBinary() + _ = yym513 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -6027,22 +6075,22 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq503[1] { + if yyq508[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym509 := z.EncBinary() - _ = yym509 + yym514 := z.EncBinary() + _ = yym514 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr503 || yy2arr503 { + if yyr508 || yy2arr508 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym511 := z.EncBinary() - _ = yym511 + yym516 := z.EncBinary() + _ = yym516 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -6051,21 +6099,21 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym512 := z.EncBinary() - _ = yym512 + yym517 := z.EncBinary() + _ = yym517 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr503 || yy2arr503 { + if yyr508 || yy2arr508 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq503[3] { + if yyq508[3] { if x.UpdatedAnnotations == nil { r.EncodeNil() } else { - yym514 := z.EncBinary() - _ = yym514 + yym519 := z.EncBinary() + _ = yym519 if false { } else { z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) @@ -6075,15 +6123,15 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq503[3] { + if yyq508[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("updatedAnnotations")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.UpdatedAnnotations == nil { r.EncodeNil() } else { - yym515 := z.EncBinary() - _ = yym515 + yym520 := z.EncBinary() + _ = yym520 if false { } else { z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) @@ -6091,18 +6139,18 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr503 || yy2arr503 { + if yyr508 || yy2arr508 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy517 := &x.RollbackTo - yy517.CodecEncodeSelf(e) + yy522 := &x.RollbackTo + yy522.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy518 := &x.RollbackTo - yy518.CodecEncodeSelf(e) + yy523 := &x.RollbackTo + yy523.CodecEncodeSelf(e) } - if yyr503 || yy2arr503 { + if yyr508 || yy2arr508 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6115,25 +6163,25 @@ func (x *DeploymentRollback) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym519 := z.DecBinary() - _ = yym519 + yym524 := z.DecBinary() + _ = yym524 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct520 := r.ContainerType() - if yyct520 == codecSelferValueTypeMap1234 { - yyl520 := r.ReadMapStart() - if yyl520 == 0 { + yyct525 := r.ContainerType() + if yyct525 == codecSelferValueTypeMap1234 { + yyl525 := r.ReadMapStart() + if yyl525 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl520, d) + x.codecDecodeSelfFromMap(yyl525, d) } - } else if yyct520 == codecSelferValueTypeArray1234 { - yyl520 := r.ReadArrayStart() - if yyl520 == 0 { + } else if yyct525 == codecSelferValueTypeArray1234 { + yyl525 := r.ReadArrayStart() + if yyl525 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl520, d) + x.codecDecodeSelfFromArray(yyl525, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6145,12 +6193,12 @@ func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys521Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys521Slc - var yyhl521 bool = l >= 0 - for yyj521 := 0; ; yyj521++ { - if yyhl521 { - if yyj521 >= l { + var yys526Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys526Slc + var yyhl526 bool = l >= 0 + for yyj526 := 0; ; yyj526++ { + if yyhl526 { + if yyj526 >= l { break } } else { @@ -6159,10 +6207,10 @@ func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys521Slc = r.DecodeBytes(yys521Slc, true, true) - yys521 := string(yys521Slc) + yys526Slc = r.DecodeBytes(yys526Slc, true, true) + yys526 := string(yys526Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys521 { + switch yys526 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" @@ -6185,25 +6233,25 @@ func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.UpdatedAnnotations = nil } else { - yyv525 := &x.UpdatedAnnotations - yym526 := z.DecBinary() - _ = yym526 + yyv530 := &x.UpdatedAnnotations + yym531 := z.DecBinary() + _ = yym531 if false { } else { - z.F.DecMapStringStringX(yyv525, false, d) + z.F.DecMapStringStringX(yyv530, false, d) } } case "rollbackTo": if r.TryDecodeAsNil() { x.RollbackTo = RollbackConfig{} } else { - yyv527 := &x.RollbackTo - yyv527.CodecDecodeSelf(d) + yyv532 := &x.RollbackTo + yyv532.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys521) - } // end switch yys521 - } // end for yyj521 + z.DecStructFieldNotFound(-1, yys526) + } // end switch yys526 + } // end for yyj526 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -6211,16 +6259,16 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj528 int - var yyb528 bool - var yyhl528 bool = l >= 0 - yyj528++ - if yyhl528 { - yyb528 = yyj528 > l + var yyj533 int + var yyb533 bool + var yyhl533 bool = l >= 0 + yyj533++ + if yyhl533 { + yyb533 = yyj533 > l } else { - yyb528 = r.CheckBreak() + yyb533 = r.CheckBreak() } - if yyb528 { + if yyb533 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6230,13 +6278,13 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.Kind = string(r.DecodeString()) } - yyj528++ - if yyhl528 { - yyb528 = yyj528 > l + yyj533++ + if yyhl533 { + yyb533 = yyj533 > l } else { - yyb528 = r.CheckBreak() + yyb533 = r.CheckBreak() } - if yyb528 { + if yyb533 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6246,13 +6294,13 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.APIVersion = string(r.DecodeString()) } - yyj528++ - if yyhl528 { - yyb528 = yyj528 > l + yyj533++ + if yyhl533 { + yyb533 = yyj533 > l } else { - yyb528 = r.CheckBreak() + yyb533 = r.CheckBreak() } - if yyb528 { + if yyb533 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6262,13 +6310,13 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.Name = string(r.DecodeString()) } - yyj528++ - if yyhl528 { - yyb528 = yyj528 > l + yyj533++ + if yyhl533 { + yyb533 = yyj533 > l } else { - yyb528 = r.CheckBreak() + yyb533 = r.CheckBreak() } - if yyb528 { + if yyb533 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6276,21 +6324,21 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.UpdatedAnnotations = nil } else { - yyv532 := &x.UpdatedAnnotations - yym533 := z.DecBinary() - _ = yym533 + yyv537 := &x.UpdatedAnnotations + yym538 := z.DecBinary() + _ = yym538 if false { } else { - z.F.DecMapStringStringX(yyv532, false, d) + z.F.DecMapStringStringX(yyv537, false, d) } } - yyj528++ - if yyhl528 { - yyb528 = yyj528 > l + yyj533++ + if yyhl533 { + yyb533 = yyj533 > l } else { - yyb528 = r.CheckBreak() + yyb533 = r.CheckBreak() } - if yyb528 { + if yyb533 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6298,21 +6346,21 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.RollbackTo = RollbackConfig{} } else { - yyv534 := &x.RollbackTo - yyv534.CodecDecodeSelf(d) + yyv539 := &x.RollbackTo + yyv539.CodecDecodeSelf(d) } for { - yyj528++ - if yyhl528 { - yyb528 = yyj528 > l + yyj533++ + if yyhl533 { + yyb533 = yyj533 > l } else { - yyb528 = r.CheckBreak() + yyb533 = r.CheckBreak() } - if yyb528 { + if yyb533 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj528-1, "") + z.DecStructFieldNotFound(yyj533-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6324,35 +6372,35 @@ func (x *RollbackConfig) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym535 := z.EncBinary() - _ = yym535 + yym540 := z.EncBinary() + _ = yym540 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep536 := !z.EncBinary() - yy2arr536 := z.EncBasicHandle().StructToArray - var yyq536 [1]bool - _, _, _ = yysep536, yyq536, yy2arr536 - const yyr536 bool = false - yyq536[0] = x.Revision != 0 - var yynn536 int - if yyr536 || yy2arr536 { + yysep541 := !z.EncBinary() + yy2arr541 := z.EncBasicHandle().StructToArray + var yyq541 [1]bool + _, _, _ = yysep541, yyq541, yy2arr541 + const yyr541 bool = false + yyq541[0] = x.Revision != 0 + var yynn541 int + if yyr541 || yy2arr541 { r.EncodeArrayStart(1) } else { - yynn536 = 0 - for _, b := range yyq536 { + yynn541 = 0 + for _, b := range yyq541 { if b { - yynn536++ + yynn541++ } } - r.EncodeMapStart(yynn536) - yynn536 = 0 + r.EncodeMapStart(yynn541) + yynn541 = 0 } - if yyr536 || yy2arr536 { + if yyr541 || yy2arr541 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq536[0] { - yym538 := z.EncBinary() - _ = yym538 + if yyq541[0] { + yym543 := z.EncBinary() + _ = yym543 if false { } else { r.EncodeInt(int64(x.Revision)) @@ -6361,19 +6409,19 @@ func (x *RollbackConfig) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq536[0] { + if yyq541[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("revision")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym539 := z.EncBinary() - _ = yym539 + yym544 := z.EncBinary() + _ = yym544 if false { } else { r.EncodeInt(int64(x.Revision)) } } } - if yyr536 || yy2arr536 { + if yyr541 || yy2arr541 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6386,25 +6434,25 @@ func (x *RollbackConfig) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym540 := z.DecBinary() - _ = yym540 + yym545 := z.DecBinary() + _ = yym545 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct541 := r.ContainerType() - if yyct541 == codecSelferValueTypeMap1234 { - yyl541 := r.ReadMapStart() - if yyl541 == 0 { + yyct546 := r.ContainerType() + if yyct546 == codecSelferValueTypeMap1234 { + yyl546 := r.ReadMapStart() + if yyl546 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl541, d) + x.codecDecodeSelfFromMap(yyl546, d) } - } else if yyct541 == codecSelferValueTypeArray1234 { - yyl541 := r.ReadArrayStart() - if yyl541 == 0 { + } else if yyct546 == codecSelferValueTypeArray1234 { + yyl546 := r.ReadArrayStart() + if yyl546 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl541, d) + x.codecDecodeSelfFromArray(yyl546, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6416,12 +6464,12 @@ func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys542Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys542Slc - var yyhl542 bool = l >= 0 - for yyj542 := 0; ; yyj542++ { - if yyhl542 { - if yyj542 >= l { + var yys547Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys547Slc + var yyhl547 bool = l >= 0 + for yyj547 := 0; ; yyj547++ { + if yyhl547 { + if yyj547 >= l { break } } else { @@ -6430,10 +6478,10 @@ func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys542Slc = r.DecodeBytes(yys542Slc, true, true) - yys542 := string(yys542Slc) + yys547Slc = r.DecodeBytes(yys547Slc, true, true) + yys547 := string(yys547Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys542 { + switch yys547 { case "revision": if r.TryDecodeAsNil() { x.Revision = 0 @@ -6441,9 +6489,9 @@ func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.Revision = int64(r.DecodeInt(64)) } default: - z.DecStructFieldNotFound(-1, yys542) - } // end switch yys542 - } // end for yyj542 + z.DecStructFieldNotFound(-1, yys547) + } // end switch yys547 + } // end for yyj547 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -6451,16 +6499,16 @@ func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj544 int - var yyb544 bool - var yyhl544 bool = l >= 0 - yyj544++ - if yyhl544 { - yyb544 = yyj544 > l + var yyj549 int + var yyb549 bool + var yyhl549 bool = l >= 0 + yyj549++ + if yyhl549 { + yyb549 = yyj549 > l } else { - yyb544 = r.CheckBreak() + yyb549 = r.CheckBreak() } - if yyb544 { + if yyb549 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6471,17 +6519,17 @@ func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.Revision = int64(r.DecodeInt(64)) } for { - yyj544++ - if yyhl544 { - yyb544 = yyj544 > l + yyj549++ + if yyhl549 { + yyb549 = yyj549 > l } else { - yyb544 = r.CheckBreak() + yyb549 = r.CheckBreak() } - if yyb544 { + if yyb549 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj544-1, "") + z.DecStructFieldNotFound(yyj549-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6493,49 +6541,49 @@ func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym546 := z.EncBinary() - _ = yym546 + yym551 := z.EncBinary() + _ = yym551 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep547 := !z.EncBinary() - yy2arr547 := z.EncBasicHandle().StructToArray - var yyq547 [2]bool - _, _, _ = yysep547, yyq547, yy2arr547 - const yyr547 bool = false - yyq547[0] = x.Type != "" - yyq547[1] = x.RollingUpdate != nil - var yynn547 int - if yyr547 || yy2arr547 { + yysep552 := !z.EncBinary() + yy2arr552 := z.EncBasicHandle().StructToArray + var yyq552 [2]bool + _, _, _ = yysep552, yyq552, yy2arr552 + const yyr552 bool = false + yyq552[0] = x.Type != "" + yyq552[1] = x.RollingUpdate != nil + var yynn552 int + if yyr552 || yy2arr552 { r.EncodeArrayStart(2) } else { - yynn547 = 0 - for _, b := range yyq547 { + yynn552 = 0 + for _, b := range yyq552 { if b { - yynn547++ + yynn552++ } } - r.EncodeMapStart(yynn547) - yynn547 = 0 + r.EncodeMapStart(yynn552) + yynn552 = 0 } - if yyr547 || yy2arr547 { + if yyr552 || yy2arr552 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq547[0] { + if yyq552[0] { x.Type.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq547[0] { + if yyq552[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } } - if yyr547 || yy2arr547 { + if yyr552 || yy2arr552 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq547[1] { + if yyq552[1] { if x.RollingUpdate == nil { r.EncodeNil() } else { @@ -6545,7 +6593,7 @@ func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq547[1] { + if yyq552[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -6556,7 +6604,7 @@ func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr547 || yy2arr547 { + if yyr552 || yy2arr552 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6569,25 +6617,25 @@ func (x *DeploymentStrategy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym550 := z.DecBinary() - _ = yym550 + yym555 := z.DecBinary() + _ = yym555 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct551 := r.ContainerType() - if yyct551 == codecSelferValueTypeMap1234 { - yyl551 := r.ReadMapStart() - if yyl551 == 0 { + yyct556 := r.ContainerType() + if yyct556 == codecSelferValueTypeMap1234 { + yyl556 := r.ReadMapStart() + if yyl556 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl551, d) + x.codecDecodeSelfFromMap(yyl556, d) } - } else if yyct551 == codecSelferValueTypeArray1234 { - yyl551 := r.ReadArrayStart() - if yyl551 == 0 { + } else if yyct556 == codecSelferValueTypeArray1234 { + yyl556 := r.ReadArrayStart() + if yyl556 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl551, d) + x.codecDecodeSelfFromArray(yyl556, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6599,12 +6647,12 @@ func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys552Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys552Slc - var yyhl552 bool = l >= 0 - for yyj552 := 0; ; yyj552++ { - if yyhl552 { - if yyj552 >= l { + var yys557Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys557Slc + var yyhl557 bool = l >= 0 + for yyj557 := 0; ; yyj557++ { + if yyhl557 { + if yyj557 >= l { break } } else { @@ -6613,10 +6661,10 @@ func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys552Slc = r.DecodeBytes(yys552Slc, true, true) - yys552 := string(yys552Slc) + yys557Slc = r.DecodeBytes(yys557Slc, true, true) + yys557 := string(yys557Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys552 { + switch yys557 { case "type": if r.TryDecodeAsNil() { x.Type = "" @@ -6635,9 +6683,9 @@ func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) x.RollingUpdate.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys552) - } // end switch yys552 - } // end for yyj552 + z.DecStructFieldNotFound(-1, yys557) + } // end switch yys557 + } // end for yyj557 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -6645,16 +6693,16 @@ func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj555 int - var yyb555 bool - var yyhl555 bool = l >= 0 - yyj555++ - if yyhl555 { - yyb555 = yyj555 > l + var yyj560 int + var yyb560 bool + var yyhl560 bool = l >= 0 + yyj560++ + if yyhl560 { + yyb560 = yyj560 > l } else { - yyb555 = r.CheckBreak() + yyb560 = r.CheckBreak() } - if yyb555 { + if yyb560 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6664,13 +6712,13 @@ func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.Type = DeploymentStrategyType(r.DecodeString()) } - yyj555++ - if yyhl555 { - yyb555 = yyj555 > l + yyj560++ + if yyhl560 { + yyb560 = yyj560 > l } else { - yyb555 = r.CheckBreak() + yyb560 = r.CheckBreak() } - if yyb555 { + if yyb560 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6686,17 +6734,17 @@ func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decode x.RollingUpdate.CodecDecodeSelf(d) } for { - yyj555++ - if yyhl555 { - yyb555 = yyj555 > l + yyj560++ + if yyhl560 { + yyb560 = yyj560 > l } else { - yyb555 = r.CheckBreak() + yyb560 = r.CheckBreak() } - if yyb555 { + if yyb560 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj555-1, "") + z.DecStructFieldNotFound(yyj560-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6705,8 +6753,8 @@ func (x DeploymentStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym558 := z.EncBinary() - _ = yym558 + yym563 := z.EncBinary() + _ = yym563 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -6718,8 +6766,8 @@ func (x *DeploymentStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym559 := z.DecBinary() - _ = yym559 + yym564 := z.DecBinary() + _ = yym564 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -6734,69 +6782,35 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym560 := z.EncBinary() - _ = yym560 + yym565 := z.EncBinary() + _ = yym565 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep561 := !z.EncBinary() - yy2arr561 := z.EncBasicHandle().StructToArray - var yyq561 [3]bool - _, _, _ = yysep561, yyq561, yy2arr561 - const yyr561 bool = false - yyq561[0] = true - yyq561[1] = true - yyq561[2] = x.MinReadySeconds != 0 - var yynn561 int - if yyr561 || yy2arr561 { - r.EncodeArrayStart(3) + yysep566 := !z.EncBinary() + yy2arr566 := z.EncBasicHandle().StructToArray + var yyq566 [2]bool + _, _, _ = yysep566, yyq566, yy2arr566 + const yyr566 bool = false + yyq566[0] = true + yyq566[1] = true + var yynn566 int + if yyr566 || yy2arr566 { + r.EncodeArrayStart(2) } else { - yynn561 = 0 - for _, b := range yyq561 { + yynn566 = 0 + for _, b := range yyq566 { if b { - yynn561++ + yynn566++ } } - r.EncodeMapStart(yynn561) - yynn561 = 0 + r.EncodeMapStart(yynn566) + yynn566 = 0 } - if yyr561 || yy2arr561 { + if yyr566 || yy2arr566 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq561[0] { - yy563 := &x.MaxUnavailable - yym564 := z.EncBinary() - _ = yym564 - if false { - } else if z.HasExtensions() && z.EncExt(yy563) { - } else if !yym564 && z.IsJSONHandle() { - z.EncJSONMarshal(yy563) - } else { - z.EncFallback(yy563) - } - } else { - r.EncodeNil() - } - } else { - if yyq561[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy565 := &x.MaxUnavailable - yym566 := z.EncBinary() - _ = yym566 - if false { - } else if z.HasExtensions() && z.EncExt(yy565) { - } else if !yym566 && z.IsJSONHandle() { - z.EncJSONMarshal(yy565) - } else { - z.EncFallback(yy565) - } - } - } - if yyr561 || yy2arr561 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq561[1] { - yy568 := &x.MaxSurge + if yyq566[0] { + yy568 := &x.MaxUnavailable yym569 := z.EncBinary() _ = yym569 if false { @@ -6810,11 +6824,11 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq561[1] { + if yyq566[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxSurge")) + r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy570 := &x.MaxSurge + yy570 := &x.MaxUnavailable yym571 := z.EncBinary() _ = yym571 if false { @@ -6826,32 +6840,40 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr561 || yy2arr561 { + if yyr566 || yy2arr566 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq561[2] { - yym573 := z.EncBinary() - _ = yym573 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq561[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyq566[1] { + yy573 := &x.MaxSurge yym574 := z.EncBinary() _ = yym574 if false { + } else if z.HasExtensions() && z.EncExt(yy573) { + } else if !yym574 && z.IsJSONHandle() { + z.EncJSONMarshal(yy573) } else { - r.EncodeInt(int64(x.MinReadySeconds)) + z.EncFallback(yy573) + } + } else { + r.EncodeNil() + } + } else { + if yyq566[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("maxSurge")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy575 := &x.MaxSurge + yym576 := z.EncBinary() + _ = yym576 + if false { + } else if z.HasExtensions() && z.EncExt(yy575) { + } else if !yym576 && z.IsJSONHandle() { + z.EncJSONMarshal(yy575) + } else { + z.EncFallback(yy575) } } } - if yyr561 || yy2arr561 { + if yyr566 || yy2arr566 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6864,25 +6886,25 @@ func (x *RollingUpdateDeployment) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym575 := z.DecBinary() - _ = yym575 + yym577 := z.DecBinary() + _ = yym577 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct576 := r.ContainerType() - if yyct576 == codecSelferValueTypeMap1234 { - yyl576 := r.ReadMapStart() - if yyl576 == 0 { + yyct578 := r.ContainerType() + if yyct578 == codecSelferValueTypeMap1234 { + yyl578 := r.ReadMapStart() + if yyl578 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl576, d) + x.codecDecodeSelfFromMap(yyl578, d) } - } else if yyct576 == codecSelferValueTypeArray1234 { - yyl576 := r.ReadArrayStart() - if yyl576 == 0 { + } else if yyct578 == codecSelferValueTypeArray1234 { + yyl578 := r.ReadArrayStart() + if yyl578 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl576, d) + x.codecDecodeSelfFromArray(yyl578, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6894,12 +6916,12 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys577Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys577Slc - var yyhl577 bool = l >= 0 - for yyj577 := 0; ; yyj577++ { - if yyhl577 { - if yyj577 >= l { + var yys579Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys579Slc + var yyhl579 bool = l >= 0 + for yyj579 := 0; ; yyj579++ { + if yyhl579 { + if yyj579 >= l { break } } else { @@ -6908,30 +6930,15 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys577Slc = r.DecodeBytes(yys577Slc, true, true) - yys577 := string(yys577Slc) + yys579Slc = r.DecodeBytes(yys579Slc, true, true) + yys579 := string(yys579Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys577 { + switch yys579 { case "maxUnavailable": if r.TryDecodeAsNil() { x.MaxUnavailable = pkg6_intstr.IntOrString{} } else { - yyv578 := &x.MaxUnavailable - yym579 := z.DecBinary() - _ = yym579 - if false { - } else if z.HasExtensions() && z.DecExt(yyv578) { - } else if !yym579 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv578) - } else { - z.DecFallback(yyv578, false) - } - } - case "maxSurge": - if r.TryDecodeAsNil() { - x.MaxSurge = pkg6_intstr.IntOrString{} - } else { - yyv580 := &x.MaxSurge + yyv580 := &x.MaxUnavailable yym581 := z.DecBinary() _ = yym581 if false { @@ -6942,16 +6949,25 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Dec z.DecFallback(yyv580, false) } } - case "minReadySeconds": + case "maxSurge": if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 + x.MaxSurge = pkg6_intstr.IntOrString{} } else { - x.MinReadySeconds = int(r.DecodeInt(codecSelferBitsize1234)) + yyv582 := &x.MaxSurge + yym583 := z.DecBinary() + _ = yym583 + if false { + } else if z.HasExtensions() && z.DecExt(yyv582) { + } else if !yym583 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv582) + } else { + z.DecFallback(yyv582, false) + } } default: - z.DecStructFieldNotFound(-1, yys577) - } // end switch yys577 - } // end for yyj577 + z.DecStructFieldNotFound(-1, yys579) + } // end switch yys579 + } // end for yyj579 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -6959,16 +6975,16 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj583 int - var yyb583 bool - var yyhl583 bool = l >= 0 - yyj583++ - if yyhl583 { - yyb583 = yyj583 > l + var yyj584 int + var yyb584 bool + var yyhl584 bool = l >= 0 + yyj584++ + if yyhl584 { + yyb584 = yyj584 > l } else { - yyb583 = r.CheckBreak() + yyb584 = r.CheckBreak() } - if yyb583 { + if yyb584 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6976,24 +6992,24 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.MaxUnavailable = pkg6_intstr.IntOrString{} } else { - yyv584 := &x.MaxUnavailable - yym585 := z.DecBinary() - _ = yym585 + yyv585 := &x.MaxUnavailable + yym586 := z.DecBinary() + _ = yym586 if false { - } else if z.HasExtensions() && z.DecExt(yyv584) { - } else if !yym585 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv584) + } else if z.HasExtensions() && z.DecExt(yyv585) { + } else if !yym586 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv585) } else { - z.DecFallback(yyv584, false) + z.DecFallback(yyv585, false) } } - yyj583++ - if yyhl583 { - yyb583 = yyj583 > l + yyj584++ + if yyhl584 { + yyb584 = yyj584 > l } else { - yyb583 = r.CheckBreak() + yyb584 = r.CheckBreak() } - if yyb583 { + if yyb584 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7001,45 +7017,29 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.MaxSurge = pkg6_intstr.IntOrString{} } else { - yyv586 := &x.MaxSurge - yym587 := z.DecBinary() - _ = yym587 + yyv587 := &x.MaxSurge + yym588 := z.DecBinary() + _ = yym588 if false { - } else if z.HasExtensions() && z.DecExt(yyv586) { - } else if !yym587 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv586) + } else if z.HasExtensions() && z.DecExt(yyv587) { + } else if !yym588 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv587) } else { - z.DecFallback(yyv586, false) + z.DecFallback(yyv587, false) } } - yyj583++ - if yyhl583 { - yyb583 = yyj583 > l - } else { - yyb583 = r.CheckBreak() - } - if yyb583 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int(r.DecodeInt(codecSelferBitsize1234)) - } for { - yyj583++ - if yyhl583 { - yyb583 = yyj583 > l + yyj584++ + if yyhl584 { + yyb584 = yyj584 > l } else { - yyb583 = r.CheckBreak() + yyb584 = r.CheckBreak() } - if yyb583 { + if yyb584 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj583-1, "") + z.DecStructFieldNotFound(yyj584-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -17492,7 +17492,7 @@ func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decode yyrg1441 := len(yyv1441) > 0 yyv21441 := yyv1441 - yyrl1441, yyrt1441 = z.DecInferLen(yyl1441, z.DecBasicHandle().MaxInitLen, 632) + yyrl1441, yyrt1441 = z.DecInferLen(yyl1441, z.DecBasicHandle().MaxInitLen, 640) if yyrt1441 { if yyrl1441 <= cap(yyv1441) { yyv1441 = yyv1441[:yyrl1441] diff --git a/pkg/apis/extensions/types.go b/pkg/apis/extensions/types.go index 142d8e52f69..91e4d1b73be 100644 --- a/pkg/apis/extensions/types.go +++ b/pkg/apis/extensions/types.go @@ -243,6 +243,11 @@ type DeploymentSpec struct { // The deployment strategy to use to replace existing pods with new ones. Strategy DeploymentStrategy `json:"strategy,omitempty"` + // Minimum number of seconds for which a newly created pod should be ready + // without any of its container crashing, for it to be considered available. + // Defaults to 0 (pod will be considered available as soon as it is ready) + MinReadySeconds int `json:"minReadySeconds,omitempty"` + // The number of old ReplicationControllers to retain to allow rollback. // This is a pointer to distinguish between explicit zero and not specified. RevisionHistoryLimit *int `json:"revisionHistoryLimit,omitempty"` @@ -335,11 +340,6 @@ type RollingUpdateDeployment struct { // new RC can be scaled up further, ensuring that total number of pods running // at any time during the update is atmost 130% of original pods. MaxSurge intstr.IntOrString `json:"maxSurge,omitempty"` - - // Minimum number of seconds for which a newly created pod should be ready - // without any of its container crashing, for it to be considered available. - // Defaults to 0 (pod will be considered available as soon as it is ready) - MinReadySeconds int `json:"minReadySeconds,omitempty"` } type DeploymentStatus struct { diff --git a/pkg/apis/extensions/v1beta1/conversion.go b/pkg/apis/extensions/v1beta1/conversion.go index 330e34e911c..3ed3f446ba6 100644 --- a/pkg/apis/extensions/v1beta1/conversion.go +++ b/pkg/apis/extensions/v1beta1/conversion.go @@ -266,6 +266,7 @@ func Convert_extensions_DeploymentSpec_To_v1beta1_DeploymentSpec(in *extensions. } out.UniqueLabelKey = new(string) *out.UniqueLabelKey = in.UniqueLabelKey + out.MinReadySeconds = int32(in.MinReadySeconds) out.Paused = in.Paused if in.RollbackTo != nil { out.RollbackTo = new(RollbackConfig) @@ -304,6 +305,7 @@ func Convert_v1beta1_DeploymentSpec_To_extensions_DeploymentSpec(in *DeploymentS if in.UniqueLabelKey != nil { out.UniqueLabelKey = *in.UniqueLabelKey } + out.MinReadySeconds = int(in.MinReadySeconds) out.Paused = in.Paused if in.RollbackTo != nil { out.RollbackTo = new(extensions.RollbackConfig) @@ -362,7 +364,6 @@ func Convert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDeployme if err := s.Convert(&in.MaxSurge, out.MaxSurge, 0); err != nil { return err } - out.MinReadySeconds = int32(in.MinReadySeconds) return nil } @@ -376,7 +377,6 @@ func Convert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployme if err := s.Convert(in.MaxSurge, &out.MaxSurge, 0); err != nil { return err } - out.MinReadySeconds = int(in.MinReadySeconds) return nil } diff --git a/pkg/apis/extensions/v1beta1/conversion_generated.go b/pkg/apis/extensions/v1beta1/conversion_generated.go index 29afdcf664d..fd6c399ce45 100644 --- a/pkg/apis/extensions/v1beta1/conversion_generated.go +++ b/pkg/apis/extensions/v1beta1/conversion_generated.go @@ -2727,6 +2727,7 @@ func autoConvert_extensions_DeploymentSpec_To_v1beta1_DeploymentSpec(in *extensi if err := Convert_extensions_DeploymentStrategy_To_v1beta1_DeploymentStrategy(&in.Strategy, &out.Strategy, s); err != nil { return err } + out.MinReadySeconds = int32(in.MinReadySeconds) if in.RevisionHistoryLimit != nil { out.RevisionHistoryLimit = new(int32) *out.RevisionHistoryLimit = int32(*in.RevisionHistoryLimit) @@ -3430,7 +3431,6 @@ func autoConvert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDepl if err := s.Convert(&in.MaxSurge, &out.MaxSurge, 0); err != nil { return err } - out.MinReadySeconds = int32(in.MinReadySeconds) return nil } @@ -3902,6 +3902,7 @@ func autoConvert_v1beta1_DeploymentSpec_To_extensions_DeploymentSpec(in *Deploym if err := s.Convert(&in.Strategy, &out.Strategy, 0); err != nil { return err } + out.MinReadySeconds = int(in.MinReadySeconds) if in.RevisionHistoryLimit != nil { out.RevisionHistoryLimit = new(int) *out.RevisionHistoryLimit = int(*in.RevisionHistoryLimit) @@ -4608,7 +4609,6 @@ func autoConvert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDepl } // in.MaxUnavailable has no peer in out // in.MaxSurge has no peer in out - out.MinReadySeconds = int(in.MinReadySeconds) return nil } diff --git a/pkg/apis/extensions/v1beta1/deep_copy_generated.go b/pkg/apis/extensions/v1beta1/deep_copy_generated.go index 695908cd109..78e5b68a5f9 100644 --- a/pkg/apis/extensions/v1beta1/deep_copy_generated.go +++ b/pkg/apis/extensions/v1beta1/deep_copy_generated.go @@ -1167,6 +1167,7 @@ func deepCopy_v1beta1_DeploymentSpec(in DeploymentSpec, out *DeploymentSpec, c * if err := deepCopy_v1beta1_DeploymentStrategy(in.Strategy, &out.Strategy, c); err != nil { return err } + out.MinReadySeconds = in.MinReadySeconds if in.RevisionHistoryLimit != nil { out.RevisionHistoryLimit = new(int32) *out.RevisionHistoryLimit = *in.RevisionHistoryLimit @@ -1696,7 +1697,6 @@ func deepCopy_v1beta1_RollingUpdateDeployment(in RollingUpdateDeployment, out *R } else { out.MaxSurge = nil } - out.MinReadySeconds = in.MinReadySeconds return nil } diff --git a/pkg/apis/extensions/v1beta1/types.generated.go b/pkg/apis/extensions/v1beta1/types.generated.go index 4417dd0c90c..6c3a0f6765b 100644 --- a/pkg/apis/extensions/v1beta1/types.generated.go +++ b/pkg/apis/extensions/v1beta1/types.generated.go @@ -5426,19 +5426,20 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep453 := !z.EncBinary() yy2arr453 := z.EncBasicHandle().StructToArray - var yyq453 [8]bool + var yyq453 [9]bool _, _, _ = yysep453, yyq453, yy2arr453 const yyr453 bool = false yyq453[0] = x.Replicas != nil yyq453[1] = len(x.Selector) != 0 yyq453[3] = true - yyq453[4] = x.RevisionHistoryLimit != nil - yyq453[5] = x.UniqueLabelKey != nil - yyq453[6] = x.Paused != false - yyq453[7] = x.RollbackTo != nil + yyq453[4] = x.MinReadySeconds != 0 + yyq453[5] = x.RevisionHistoryLimit != nil + yyq453[6] = x.UniqueLabelKey != nil + yyq453[7] = x.Paused != false + yyq453[8] = x.RollbackTo != nil var yynn453 int if yyr453 || yy2arr453 { - r.EncodeArrayStart(8) + r.EncodeArrayStart(9) } else { yynn453 = 1 for _, b := range yyq453 { @@ -5548,50 +5549,40 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { if yyr453 || yy2arr453 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq453[4] { - if x.RevisionHistoryLimit == nil { - r.EncodeNil() + yym469 := z.EncBinary() + _ = yym469 + if false { } else { - yy469 := *x.RevisionHistoryLimit - yym470 := z.EncBinary() - _ = yym470 - if false { - } else { - r.EncodeInt(int64(yy469)) - } + r.EncodeInt(int64(x.MinReadySeconds)) } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { if yyq453[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) + r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RevisionHistoryLimit == nil { - r.EncodeNil() + yym470 := z.EncBinary() + _ = yym470 + if false { } else { - yy471 := *x.RevisionHistoryLimit - yym472 := z.EncBinary() - _ = yym472 - if false { - } else { - r.EncodeInt(int64(yy471)) - } + r.EncodeInt(int64(x.MinReadySeconds)) } } } if yyr453 || yy2arr453 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq453[5] { - if x.UniqueLabelKey == nil { + if x.RevisionHistoryLimit == nil { r.EncodeNil() } else { - yy474 := *x.UniqueLabelKey - yym475 := z.EncBinary() - _ = yym475 + yy472 := *x.RevisionHistoryLimit + yym473 := z.EncBinary() + _ = yym473 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yy474)) + r.EncodeInt(int64(yy472)) } } } else { @@ -5600,17 +5591,17 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { } else { if yyq453[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uniqueLabelKey")) + r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.UniqueLabelKey == nil { + if x.RevisionHistoryLimit == nil { r.EncodeNil() } else { - yy476 := *x.UniqueLabelKey - yym477 := z.EncBinary() - _ = yym477 + yy474 := *x.RevisionHistoryLimit + yym475 := z.EncBinary() + _ = yym475 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yy476)) + r.EncodeInt(int64(yy474)) } } } @@ -5618,8 +5609,43 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { if yyr453 || yy2arr453 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq453[6] { - yym479 := z.EncBinary() - _ = yym479 + if x.UniqueLabelKey == nil { + r.EncodeNil() + } else { + yy477 := *x.UniqueLabelKey + yym478 := z.EncBinary() + _ = yym478 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yy477)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq453[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("uniqueLabelKey")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.UniqueLabelKey == nil { + r.EncodeNil() + } else { + yy479 := *x.UniqueLabelKey + yym480 := z.EncBinary() + _ = yym480 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yy479)) + } + } + } + } + if yyr453 || yy2arr453 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq453[7] { + yym482 := z.EncBinary() + _ = yym482 if false { } else { r.EncodeBool(bool(x.Paused)) @@ -5628,12 +5654,12 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq453[6] { + if yyq453[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("paused")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym480 := z.EncBinary() - _ = yym480 + yym483 := z.EncBinary() + _ = yym483 if false { } else { r.EncodeBool(bool(x.Paused)) @@ -5642,7 +5668,7 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { } if yyr453 || yy2arr453 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[7] { + if yyq453[8] { if x.RollbackTo == nil { r.EncodeNil() } else { @@ -5652,7 +5678,7 @@ func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq453[7] { + if yyq453[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -5676,25 +5702,25 @@ func (x *DeploymentSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym482 := z.DecBinary() - _ = yym482 + yym485 := z.DecBinary() + _ = yym485 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct483 := r.ContainerType() - if yyct483 == codecSelferValueTypeMap1234 { - yyl483 := r.ReadMapStart() - if yyl483 == 0 { + yyct486 := r.ContainerType() + if yyct486 == codecSelferValueTypeMap1234 { + yyl486 := r.ReadMapStart() + if yyl486 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl483, d) + x.codecDecodeSelfFromMap(yyl486, d) } - } else if yyct483 == codecSelferValueTypeArray1234 { - yyl483 := r.ReadArrayStart() - if yyl483 == 0 { + } else if yyct486 == codecSelferValueTypeArray1234 { + yyl486 := r.ReadArrayStart() + if yyl486 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl483, d) + x.codecDecodeSelfFromArray(yyl486, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -5706,12 +5732,12 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys484Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys484Slc - var yyhl484 bool = l >= 0 - for yyj484 := 0; ; yyj484++ { - if yyhl484 { - if yyj484 >= l { + var yys487Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys487Slc + var yyhl487 bool = l >= 0 + for yyj487 := 0; ; yyj487++ { + if yyhl487 { + if yyj487 >= l { break } } else { @@ -5720,10 +5746,10 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys484Slc = r.DecodeBytes(yys484Slc, true, true) - yys484 := string(yys484Slc) + yys487Slc = r.DecodeBytes(yys487Slc, true, true) + yys487 := string(yys487Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys484 { + switch yys487 { case "replicas": if r.TryDecodeAsNil() { if x.Replicas != nil { @@ -5733,8 +5759,8 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.Replicas == nil { x.Replicas = new(int32) } - yym486 := z.DecBinary() - _ = yym486 + yym489 := z.DecBinary() + _ = yym489 if false { } else { *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) @@ -5744,27 +5770,33 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv487 := &x.Selector - yym488 := z.DecBinary() - _ = yym488 + yyv490 := &x.Selector + yym491 := z.DecBinary() + _ = yym491 if false { } else { - z.F.DecMapStringStringX(yyv487, false, d) + z.F.DecMapStringStringX(yyv490, false, d) } } case "template": if r.TryDecodeAsNil() { x.Template = pkg2_v1.PodTemplateSpec{} } else { - yyv489 := &x.Template - yyv489.CodecDecodeSelf(d) + yyv492 := &x.Template + yyv492.CodecDecodeSelf(d) } case "strategy": if r.TryDecodeAsNil() { x.Strategy = DeploymentStrategy{} } else { - yyv490 := &x.Strategy - yyv490.CodecDecodeSelf(d) + yyv493 := &x.Strategy + yyv493.CodecDecodeSelf(d) + } + case "minReadySeconds": + if r.TryDecodeAsNil() { + x.MinReadySeconds = 0 + } else { + x.MinReadySeconds = int32(r.DecodeInt(32)) } case "revisionHistoryLimit": if r.TryDecodeAsNil() { @@ -5775,8 +5807,8 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.RevisionHistoryLimit == nil { x.RevisionHistoryLimit = new(int32) } - yym492 := z.DecBinary() - _ = yym492 + yym496 := z.DecBinary() + _ = yym496 if false { } else { *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) @@ -5791,8 +5823,8 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.UniqueLabelKey == nil { x.UniqueLabelKey = new(string) } - yym494 := z.DecBinary() - _ = yym494 + yym498 := z.DecBinary() + _ = yym498 if false { } else { *((*string)(x.UniqueLabelKey)) = r.DecodeString() @@ -5816,9 +5848,9 @@ func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.RollbackTo.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys484) - } // end switch yys484 - } // end for yyj484 + z.DecStructFieldNotFound(-1, yys487) + } // end switch yys487 + } // end for yyj487 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -5826,16 +5858,16 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj497 int - var yyb497 bool - var yyhl497 bool = l >= 0 - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + var yyj501 int + var yyb501 bool + var yyhl501 bool = l >= 0 + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5848,20 +5880,20 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Replicas == nil { x.Replicas = new(int32) } - yym499 := z.DecBinary() - _ = yym499 + yym503 := z.DecBinary() + _ = yym503 if false { } else { *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) } } - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5869,21 +5901,21 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv500 := &x.Selector - yym501 := z.DecBinary() - _ = yym501 + yyv504 := &x.Selector + yym505 := z.DecBinary() + _ = yym505 if false { } else { - z.F.DecMapStringStringX(yyv500, false, d) + z.F.DecMapStringStringX(yyv504, false, d) } } - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5891,16 +5923,16 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Template = pkg2_v1.PodTemplateSpec{} } else { - yyv502 := &x.Template - yyv502.CodecDecodeSelf(d) + yyv506 := &x.Template + yyv506.CodecDecodeSelf(d) } - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5908,16 +5940,32 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Strategy = DeploymentStrategy{} } else { - yyv503 := &x.Strategy - yyv503.CodecDecodeSelf(d) + yyv507 := &x.Strategy + yyv507.CodecDecodeSelf(d) } - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MinReadySeconds = 0 + } else { + x.MinReadySeconds = int32(r.DecodeInt(32)) + } + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l + } else { + yyb501 = r.CheckBreak() + } + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5930,20 +5978,20 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.RevisionHistoryLimit == nil { x.RevisionHistoryLimit = new(int32) } - yym505 := z.DecBinary() - _ = yym505 + yym510 := z.DecBinary() + _ = yym510 if false { } else { *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) } } - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5956,20 +6004,20 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.UniqueLabelKey == nil { x.UniqueLabelKey = new(string) } - yym507 := z.DecBinary() - _ = yym507 + yym512 := z.DecBinary() + _ = yym512 if false { } else { *((*string)(x.UniqueLabelKey)) = r.DecodeString() } } - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5979,13 +6027,13 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } else { x.Paused = bool(r.DecodeBool()) } - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6001,17 +6049,17 @@ func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.RollbackTo.CodecDecodeSelf(d) } for { - yyj497++ - if yyhl497 { - yyb497 = yyj497 > l + yyj501++ + if yyhl501 { + yyb501 = yyj501 > l } else { - yyb497 = r.CheckBreak() + yyb501 = r.CheckBreak() } - if yyb497 { + if yyb501 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj497-1, "") + z.DecStructFieldNotFound(yyj501-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6023,37 +6071,37 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym510 := z.EncBinary() - _ = yym510 + yym515 := z.EncBinary() + _ = yym515 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep511 := !z.EncBinary() - yy2arr511 := z.EncBasicHandle().StructToArray - var yyq511 [5]bool - _, _, _ = yysep511, yyq511, yy2arr511 - const yyr511 bool = false - yyq511[0] = x.Kind != "" - yyq511[1] = x.APIVersion != "" - yyq511[3] = len(x.UpdatedAnnotations) != 0 - var yynn511 int - if yyr511 || yy2arr511 { + yysep516 := !z.EncBinary() + yy2arr516 := z.EncBasicHandle().StructToArray + var yyq516 [5]bool + _, _, _ = yysep516, yyq516, yy2arr516 + const yyr516 bool = false + yyq516[0] = x.Kind != "" + yyq516[1] = x.APIVersion != "" + yyq516[3] = len(x.UpdatedAnnotations) != 0 + var yynn516 int + if yyr516 || yy2arr516 { r.EncodeArrayStart(5) } else { - yynn511 = 2 - for _, b := range yyq511 { + yynn516 = 2 + for _, b := range yyq516 { if b { - yynn511++ + yynn516++ } } - r.EncodeMapStart(yynn511) - yynn511 = 0 + r.EncodeMapStart(yynn516) + yynn516 = 0 } - if yyr511 || yy2arr511 { + if yyr516 || yy2arr516 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq511[0] { - yym513 := z.EncBinary() - _ = yym513 + if yyq516[0] { + yym518 := z.EncBinary() + _ = yym518 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -6062,23 +6110,23 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq511[0] { + if yyq516[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym514 := z.EncBinary() - _ = yym514 + yym519 := z.EncBinary() + _ = yym519 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr511 || yy2arr511 { + if yyr516 || yy2arr516 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq511[1] { - yym516 := z.EncBinary() - _ = yym516 + if yyq516[1] { + yym521 := z.EncBinary() + _ = yym521 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -6087,22 +6135,22 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq511[1] { + if yyq516[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym517 := z.EncBinary() - _ = yym517 + yym522 := z.EncBinary() + _ = yym522 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr511 || yy2arr511 { + if yyr516 || yy2arr516 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym519 := z.EncBinary() - _ = yym519 + yym524 := z.EncBinary() + _ = yym524 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -6111,21 +6159,21 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym520 := z.EncBinary() - _ = yym520 + yym525 := z.EncBinary() + _ = yym525 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr511 || yy2arr511 { + if yyr516 || yy2arr516 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq511[3] { + if yyq516[3] { if x.UpdatedAnnotations == nil { r.EncodeNil() } else { - yym522 := z.EncBinary() - _ = yym522 + yym527 := z.EncBinary() + _ = yym527 if false { } else { z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) @@ -6135,15 +6183,15 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq511[3] { + if yyq516[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("updatedAnnotations")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.UpdatedAnnotations == nil { r.EncodeNil() } else { - yym523 := z.EncBinary() - _ = yym523 + yym528 := z.EncBinary() + _ = yym528 if false { } else { z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) @@ -6151,18 +6199,18 @@ func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr511 || yy2arr511 { + if yyr516 || yy2arr516 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy525 := &x.RollbackTo - yy525.CodecEncodeSelf(e) + yy530 := &x.RollbackTo + yy530.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy526 := &x.RollbackTo - yy526.CodecEncodeSelf(e) + yy531 := &x.RollbackTo + yy531.CodecEncodeSelf(e) } - if yyr511 || yy2arr511 { + if yyr516 || yy2arr516 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6175,25 +6223,25 @@ func (x *DeploymentRollback) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym527 := z.DecBinary() - _ = yym527 + yym532 := z.DecBinary() + _ = yym532 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct528 := r.ContainerType() - if yyct528 == codecSelferValueTypeMap1234 { - yyl528 := r.ReadMapStart() - if yyl528 == 0 { + yyct533 := r.ContainerType() + if yyct533 == codecSelferValueTypeMap1234 { + yyl533 := r.ReadMapStart() + if yyl533 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl528, d) + x.codecDecodeSelfFromMap(yyl533, d) } - } else if yyct528 == codecSelferValueTypeArray1234 { - yyl528 := r.ReadArrayStart() - if yyl528 == 0 { + } else if yyct533 == codecSelferValueTypeArray1234 { + yyl533 := r.ReadArrayStart() + if yyl533 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl528, d) + x.codecDecodeSelfFromArray(yyl533, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6205,12 +6253,12 @@ func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys529Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys529Slc - var yyhl529 bool = l >= 0 - for yyj529 := 0; ; yyj529++ { - if yyhl529 { - if yyj529 >= l { + var yys534Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys534Slc + var yyhl534 bool = l >= 0 + for yyj534 := 0; ; yyj534++ { + if yyhl534 { + if yyj534 >= l { break } } else { @@ -6219,10 +6267,10 @@ func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys529Slc = r.DecodeBytes(yys529Slc, true, true) - yys529 := string(yys529Slc) + yys534Slc = r.DecodeBytes(yys534Slc, true, true) + yys534 := string(yys534Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys529 { + switch yys534 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" @@ -6245,25 +6293,25 @@ func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.UpdatedAnnotations = nil } else { - yyv533 := &x.UpdatedAnnotations - yym534 := z.DecBinary() - _ = yym534 + yyv538 := &x.UpdatedAnnotations + yym539 := z.DecBinary() + _ = yym539 if false { } else { - z.F.DecMapStringStringX(yyv533, false, d) + z.F.DecMapStringStringX(yyv538, false, d) } } case "rollbackTo": if r.TryDecodeAsNil() { x.RollbackTo = RollbackConfig{} } else { - yyv535 := &x.RollbackTo - yyv535.CodecDecodeSelf(d) + yyv540 := &x.RollbackTo + yyv540.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys529) - } // end switch yys529 - } // end for yyj529 + z.DecStructFieldNotFound(-1, yys534) + } // end switch yys534 + } // end for yyj534 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -6271,16 +6319,16 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj536 int - var yyb536 bool - var yyhl536 bool = l >= 0 - yyj536++ - if yyhl536 { - yyb536 = yyj536 > l + var yyj541 int + var yyb541 bool + var yyhl541 bool = l >= 0 + yyj541++ + if yyhl541 { + yyb541 = yyj541 > l } else { - yyb536 = r.CheckBreak() + yyb541 = r.CheckBreak() } - if yyb536 { + if yyb541 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6290,13 +6338,13 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.Kind = string(r.DecodeString()) } - yyj536++ - if yyhl536 { - yyb536 = yyj536 > l + yyj541++ + if yyhl541 { + yyb541 = yyj541 > l } else { - yyb536 = r.CheckBreak() + yyb541 = r.CheckBreak() } - if yyb536 { + if yyb541 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6306,13 +6354,13 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.APIVersion = string(r.DecodeString()) } - yyj536++ - if yyhl536 { - yyb536 = yyj536 > l + yyj541++ + if yyhl541 { + yyb541 = yyj541 > l } else { - yyb536 = r.CheckBreak() + yyb541 = r.CheckBreak() } - if yyb536 { + if yyb541 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6322,13 +6370,13 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.Name = string(r.DecodeString()) } - yyj536++ - if yyhl536 { - yyb536 = yyj536 > l + yyj541++ + if yyhl541 { + yyb541 = yyj541 > l } else { - yyb536 = r.CheckBreak() + yyb541 = r.CheckBreak() } - if yyb536 { + if yyb541 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6336,21 +6384,21 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.UpdatedAnnotations = nil } else { - yyv540 := &x.UpdatedAnnotations - yym541 := z.DecBinary() - _ = yym541 + yyv545 := &x.UpdatedAnnotations + yym546 := z.DecBinary() + _ = yym546 if false { } else { - z.F.DecMapStringStringX(yyv540, false, d) + z.F.DecMapStringStringX(yyv545, false, d) } } - yyj536++ - if yyhl536 { - yyb536 = yyj536 > l + yyj541++ + if yyhl541 { + yyb541 = yyj541 > l } else { - yyb536 = r.CheckBreak() + yyb541 = r.CheckBreak() } - if yyb536 { + if yyb541 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6358,21 +6406,21 @@ func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.RollbackTo = RollbackConfig{} } else { - yyv542 := &x.RollbackTo - yyv542.CodecDecodeSelf(d) + yyv547 := &x.RollbackTo + yyv547.CodecDecodeSelf(d) } for { - yyj536++ - if yyhl536 { - yyb536 = yyj536 > l + yyj541++ + if yyhl541 { + yyb541 = yyj541 > l } else { - yyb536 = r.CheckBreak() + yyb541 = r.CheckBreak() } - if yyb536 { + if yyb541 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj536-1, "") + z.DecStructFieldNotFound(yyj541-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6384,35 +6432,35 @@ func (x *RollbackConfig) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym543 := z.EncBinary() - _ = yym543 + yym548 := z.EncBinary() + _ = yym548 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep544 := !z.EncBinary() - yy2arr544 := z.EncBasicHandle().StructToArray - var yyq544 [1]bool - _, _, _ = yysep544, yyq544, yy2arr544 - const yyr544 bool = false - yyq544[0] = x.Revision != 0 - var yynn544 int - if yyr544 || yy2arr544 { + yysep549 := !z.EncBinary() + yy2arr549 := z.EncBasicHandle().StructToArray + var yyq549 [1]bool + _, _, _ = yysep549, yyq549, yy2arr549 + const yyr549 bool = false + yyq549[0] = x.Revision != 0 + var yynn549 int + if yyr549 || yy2arr549 { r.EncodeArrayStart(1) } else { - yynn544 = 0 - for _, b := range yyq544 { + yynn549 = 0 + for _, b := range yyq549 { if b { - yynn544++ + yynn549++ } } - r.EncodeMapStart(yynn544) - yynn544 = 0 + r.EncodeMapStart(yynn549) + yynn549 = 0 } - if yyr544 || yy2arr544 { + if yyr549 || yy2arr549 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq544[0] { - yym546 := z.EncBinary() - _ = yym546 + if yyq549[0] { + yym551 := z.EncBinary() + _ = yym551 if false { } else { r.EncodeInt(int64(x.Revision)) @@ -6421,19 +6469,19 @@ func (x *RollbackConfig) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq544[0] { + if yyq549[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("revision")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym547 := z.EncBinary() - _ = yym547 + yym552 := z.EncBinary() + _ = yym552 if false { } else { r.EncodeInt(int64(x.Revision)) } } } - if yyr544 || yy2arr544 { + if yyr549 || yy2arr549 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6446,25 +6494,25 @@ func (x *RollbackConfig) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym548 := z.DecBinary() - _ = yym548 + yym553 := z.DecBinary() + _ = yym553 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct549 := r.ContainerType() - if yyct549 == codecSelferValueTypeMap1234 { - yyl549 := r.ReadMapStart() - if yyl549 == 0 { + yyct554 := r.ContainerType() + if yyct554 == codecSelferValueTypeMap1234 { + yyl554 := r.ReadMapStart() + if yyl554 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl549, d) + x.codecDecodeSelfFromMap(yyl554, d) } - } else if yyct549 == codecSelferValueTypeArray1234 { - yyl549 := r.ReadArrayStart() - if yyl549 == 0 { + } else if yyct554 == codecSelferValueTypeArray1234 { + yyl554 := r.ReadArrayStart() + if yyl554 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl549, d) + x.codecDecodeSelfFromArray(yyl554, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6476,12 +6524,12 @@ func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys550Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys550Slc - var yyhl550 bool = l >= 0 - for yyj550 := 0; ; yyj550++ { - if yyhl550 { - if yyj550 >= l { + var yys555Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys555Slc + var yyhl555 bool = l >= 0 + for yyj555 := 0; ; yyj555++ { + if yyhl555 { + if yyj555 >= l { break } } else { @@ -6490,10 +6538,10 @@ func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys550Slc = r.DecodeBytes(yys550Slc, true, true) - yys550 := string(yys550Slc) + yys555Slc = r.DecodeBytes(yys555Slc, true, true) + yys555 := string(yys555Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys550 { + switch yys555 { case "revision": if r.TryDecodeAsNil() { x.Revision = 0 @@ -6501,9 +6549,9 @@ func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.Revision = int64(r.DecodeInt(64)) } default: - z.DecStructFieldNotFound(-1, yys550) - } // end switch yys550 - } // end for yyj550 + z.DecStructFieldNotFound(-1, yys555) + } // end switch yys555 + } // end for yyj555 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -6511,16 +6559,16 @@ func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj552 int - var yyb552 bool - var yyhl552 bool = l >= 0 - yyj552++ - if yyhl552 { - yyb552 = yyj552 > l + var yyj557 int + var yyb557 bool + var yyhl557 bool = l >= 0 + yyj557++ + if yyhl557 { + yyb557 = yyj557 > l } else { - yyb552 = r.CheckBreak() + yyb557 = r.CheckBreak() } - if yyb552 { + if yyb557 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6531,17 +6579,17 @@ func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.Revision = int64(r.DecodeInt(64)) } for { - yyj552++ - if yyhl552 { - yyb552 = yyj552 > l + yyj557++ + if yyhl557 { + yyb557 = yyj557 > l } else { - yyb552 = r.CheckBreak() + yyb557 = r.CheckBreak() } - if yyb552 { + if yyb557 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj552-1, "") + z.DecStructFieldNotFound(yyj557-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6553,49 +6601,49 @@ func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym554 := z.EncBinary() - _ = yym554 + yym559 := z.EncBinary() + _ = yym559 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep555 := !z.EncBinary() - yy2arr555 := z.EncBasicHandle().StructToArray - var yyq555 [2]bool - _, _, _ = yysep555, yyq555, yy2arr555 - const yyr555 bool = false - yyq555[0] = x.Type != "" - yyq555[1] = x.RollingUpdate != nil - var yynn555 int - if yyr555 || yy2arr555 { + yysep560 := !z.EncBinary() + yy2arr560 := z.EncBasicHandle().StructToArray + var yyq560 [2]bool + _, _, _ = yysep560, yyq560, yy2arr560 + const yyr560 bool = false + yyq560[0] = x.Type != "" + yyq560[1] = x.RollingUpdate != nil + var yynn560 int + if yyr560 || yy2arr560 { r.EncodeArrayStart(2) } else { - yynn555 = 0 - for _, b := range yyq555 { + yynn560 = 0 + for _, b := range yyq560 { if b { - yynn555++ + yynn560++ } } - r.EncodeMapStart(yynn555) - yynn555 = 0 + r.EncodeMapStart(yynn560) + yynn560 = 0 } - if yyr555 || yy2arr555 { + if yyr560 || yy2arr560 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq555[0] { + if yyq560[0] { x.Type.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq555[0] { + if yyq560[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } } - if yyr555 || yy2arr555 { + if yyr560 || yy2arr560 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq555[1] { + if yyq560[1] { if x.RollingUpdate == nil { r.EncodeNil() } else { @@ -6605,7 +6653,7 @@ func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq555[1] { + if yyq560[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -6616,7 +6664,7 @@ func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr555 || yy2arr555 { + if yyr560 || yy2arr560 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6629,25 +6677,25 @@ func (x *DeploymentStrategy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym558 := z.DecBinary() - _ = yym558 + yym563 := z.DecBinary() + _ = yym563 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct559 := r.ContainerType() - if yyct559 == codecSelferValueTypeMap1234 { - yyl559 := r.ReadMapStart() - if yyl559 == 0 { + yyct564 := r.ContainerType() + if yyct564 == codecSelferValueTypeMap1234 { + yyl564 := r.ReadMapStart() + if yyl564 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl559, d) + x.codecDecodeSelfFromMap(yyl564, d) } - } else if yyct559 == codecSelferValueTypeArray1234 { - yyl559 := r.ReadArrayStart() - if yyl559 == 0 { + } else if yyct564 == codecSelferValueTypeArray1234 { + yyl564 := r.ReadArrayStart() + if yyl564 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl559, d) + x.codecDecodeSelfFromArray(yyl564, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6659,12 +6707,12 @@ func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys560Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys560Slc - var yyhl560 bool = l >= 0 - for yyj560 := 0; ; yyj560++ { - if yyhl560 { - if yyj560 >= l { + var yys565Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys565Slc + var yyhl565 bool = l >= 0 + for yyj565 := 0; ; yyj565++ { + if yyhl565 { + if yyj565 >= l { break } } else { @@ -6673,10 +6721,10 @@ func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys560Slc = r.DecodeBytes(yys560Slc, true, true) - yys560 := string(yys560Slc) + yys565Slc = r.DecodeBytes(yys565Slc, true, true) + yys565 := string(yys565Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys560 { + switch yys565 { case "type": if r.TryDecodeAsNil() { x.Type = "" @@ -6695,9 +6743,9 @@ func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) x.RollingUpdate.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys560) - } // end switch yys560 - } // end for yyj560 + z.DecStructFieldNotFound(-1, yys565) + } // end switch yys565 + } // end for yyj565 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -6705,16 +6753,16 @@ func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj563 int - var yyb563 bool - var yyhl563 bool = l >= 0 - yyj563++ - if yyhl563 { - yyb563 = yyj563 > l + var yyj568 int + var yyb568 bool + var yyhl568 bool = l >= 0 + yyj568++ + if yyhl568 { + yyb568 = yyj568 > l } else { - yyb563 = r.CheckBreak() + yyb568 = r.CheckBreak() } - if yyb563 { + if yyb568 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6724,13 +6772,13 @@ func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decode } else { x.Type = DeploymentStrategyType(r.DecodeString()) } - yyj563++ - if yyhl563 { - yyb563 = yyj563 > l + yyj568++ + if yyhl568 { + yyb568 = yyj568 > l } else { - yyb563 = r.CheckBreak() + yyb568 = r.CheckBreak() } - if yyb563 { + if yyb568 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6746,17 +6794,17 @@ func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decode x.RollingUpdate.CodecDecodeSelf(d) } for { - yyj563++ - if yyhl563 { - yyb563 = yyj563 > l + yyj568++ + if yyhl568 { + yyb568 = yyj568 > l } else { - yyb563 = r.CheckBreak() + yyb568 = r.CheckBreak() } - if yyb563 { + if yyb568 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj563-1, "") + z.DecStructFieldNotFound(yyj568-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6765,8 +6813,8 @@ func (x DeploymentStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym566 := z.EncBinary() - _ = yym566 + yym571 := z.EncBinary() + _ = yym571 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -6778,8 +6826,8 @@ func (x *DeploymentStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym567 := z.DecBinary() - _ = yym567 + yym572 := z.DecBinary() + _ = yym572 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -6794,43 +6842,42 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym568 := z.EncBinary() - _ = yym568 + yym573 := z.EncBinary() + _ = yym573 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep569 := !z.EncBinary() - yy2arr569 := z.EncBasicHandle().StructToArray - var yyq569 [3]bool - _, _, _ = yysep569, yyq569, yy2arr569 - const yyr569 bool = false - yyq569[0] = x.MaxUnavailable != nil - yyq569[1] = x.MaxSurge != nil - yyq569[2] = x.MinReadySeconds != 0 - var yynn569 int - if yyr569 || yy2arr569 { - r.EncodeArrayStart(3) + yysep574 := !z.EncBinary() + yy2arr574 := z.EncBasicHandle().StructToArray + var yyq574 [2]bool + _, _, _ = yysep574, yyq574, yy2arr574 + const yyr574 bool = false + yyq574[0] = x.MaxUnavailable != nil + yyq574[1] = x.MaxSurge != nil + var yynn574 int + if yyr574 || yy2arr574 { + r.EncodeArrayStart(2) } else { - yynn569 = 0 - for _, b := range yyq569 { + yynn574 = 0 + for _, b := range yyq574 { if b { - yynn569++ + yynn574++ } } - r.EncodeMapStart(yynn569) - yynn569 = 0 + r.EncodeMapStart(yynn574) + yynn574 = 0 } - if yyr569 || yy2arr569 { + if yyr574 || yy2arr574 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq569[0] { + if yyq574[0] { if x.MaxUnavailable == nil { r.EncodeNil() } else { - yym571 := z.EncBinary() - _ = yym571 + yym576 := z.EncBinary() + _ = yym576 if false { } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { - } else if !yym571 && z.IsJSONHandle() { + } else if !yym576 && z.IsJSONHandle() { z.EncJSONMarshal(x.MaxUnavailable) } else { z.EncFallback(x.MaxUnavailable) @@ -6840,18 +6887,18 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq569[0] { + if yyq574[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.MaxUnavailable == nil { r.EncodeNil() } else { - yym572 := z.EncBinary() - _ = yym572 + yym577 := z.EncBinary() + _ = yym577 if false { } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { - } else if !yym572 && z.IsJSONHandle() { + } else if !yym577 && z.IsJSONHandle() { z.EncJSONMarshal(x.MaxUnavailable) } else { z.EncFallback(x.MaxUnavailable) @@ -6859,17 +6906,17 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr569 || yy2arr569 { + if yyr574 || yy2arr574 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq569[1] { + if yyq574[1] { if x.MaxSurge == nil { r.EncodeNil() } else { - yym574 := z.EncBinary() - _ = yym574 + yym579 := z.EncBinary() + _ = yym579 if false { } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { - } else if !yym574 && z.IsJSONHandle() { + } else if !yym579 && z.IsJSONHandle() { z.EncJSONMarshal(x.MaxSurge) } else { z.EncFallback(x.MaxSurge) @@ -6879,18 +6926,18 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq569[1] { + if yyq574[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("maxSurge")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.MaxSurge == nil { r.EncodeNil() } else { - yym575 := z.EncBinary() - _ = yym575 + yym580 := z.EncBinary() + _ = yym580 if false { } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { - } else if !yym575 && z.IsJSONHandle() { + } else if !yym580 && z.IsJSONHandle() { z.EncJSONMarshal(x.MaxSurge) } else { z.EncFallback(x.MaxSurge) @@ -6898,32 +6945,7 @@ func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr569 || yy2arr569 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq569[2] { - yym577 := z.EncBinary() - _ = yym577 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq569[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym578 := z.EncBinary() - _ = yym578 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } - } - if yyr569 || yy2arr569 { + if yyr574 || yy2arr574 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6936,25 +6958,25 @@ func (x *RollingUpdateDeployment) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym579 := z.DecBinary() - _ = yym579 + yym581 := z.DecBinary() + _ = yym581 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct580 := r.ContainerType() - if yyct580 == codecSelferValueTypeMap1234 { - yyl580 := r.ReadMapStart() - if yyl580 == 0 { + yyct582 := r.ContainerType() + if yyct582 == codecSelferValueTypeMap1234 { + yyl582 := r.ReadMapStart() + if yyl582 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl580, d) + x.codecDecodeSelfFromMap(yyl582, d) } - } else if yyct580 == codecSelferValueTypeArray1234 { - yyl580 := r.ReadArrayStart() - if yyl580 == 0 { + } else if yyct582 == codecSelferValueTypeArray1234 { + yyl582 := r.ReadArrayStart() + if yyl582 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl580, d) + x.codecDecodeSelfFromArray(yyl582, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6966,12 +6988,12 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys581Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys581Slc - var yyhl581 bool = l >= 0 - for yyj581 := 0; ; yyj581++ { - if yyhl581 { - if yyj581 >= l { + var yys583Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys583Slc + var yyhl583 bool = l >= 0 + for yyj583 := 0; ; yyj583++ { + if yyhl583 { + if yyj583 >= l { break } } else { @@ -6980,10 +7002,10 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys581Slc = r.DecodeBytes(yys581Slc, true, true) - yys581 := string(yys581Slc) + yys583Slc = r.DecodeBytes(yys583Slc, true, true) + yys583 := string(yys583Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys581 { + switch yys583 { case "maxUnavailable": if r.TryDecodeAsNil() { if x.MaxUnavailable != nil { @@ -6993,11 +7015,11 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Dec if x.MaxUnavailable == nil { x.MaxUnavailable = new(pkg6_intstr.IntOrString) } - yym583 := z.DecBinary() - _ = yym583 + yym585 := z.DecBinary() + _ = yym585 if false { } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { - } else if !yym583 && z.IsJSONHandle() { + } else if !yym585 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.MaxUnavailable) } else { z.DecFallback(x.MaxUnavailable, false) @@ -7012,26 +7034,20 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Dec if x.MaxSurge == nil { x.MaxSurge = new(pkg6_intstr.IntOrString) } - yym585 := z.DecBinary() - _ = yym585 + yym587 := z.DecBinary() + _ = yym587 if false { } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { - } else if !yym585 && z.IsJSONHandle() { + } else if !yym587 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.MaxSurge) } else { z.DecFallback(x.MaxSurge, false) } } - case "minReadySeconds": - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } default: - z.DecStructFieldNotFound(-1, yys581) - } // end switch yys581 - } // end for yyj581 + z.DecStructFieldNotFound(-1, yys583) + } // end switch yys583 + } // end for yyj583 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -7039,16 +7055,16 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj587 int - var yyb587 bool - var yyhl587 bool = l >= 0 - yyj587++ - if yyhl587 { - yyb587 = yyj587 > l + var yyj588 int + var yyb588 bool + var yyhl588 bool = l >= 0 + yyj588++ + if yyhl588 { + yyb588 = yyj588 > l } else { - yyb587 = r.CheckBreak() + yyb588 = r.CheckBreak() } - if yyb587 { + if yyb588 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7061,23 +7077,23 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.D if x.MaxUnavailable == nil { x.MaxUnavailable = new(pkg6_intstr.IntOrString) } - yym589 := z.DecBinary() - _ = yym589 + yym590 := z.DecBinary() + _ = yym590 if false { } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { - } else if !yym589 && z.IsJSONHandle() { + } else if !yym590 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.MaxUnavailable) } else { z.DecFallback(x.MaxUnavailable, false) } } - yyj587++ - if yyhl587 { - yyb587 = yyj587 > l + yyj588++ + if yyhl588 { + yyb588 = yyj588 > l } else { - yyb587 = r.CheckBreak() + yyb588 = r.CheckBreak() } - if yyb587 { + if yyb588 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7090,44 +7106,28 @@ func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.D if x.MaxSurge == nil { x.MaxSurge = new(pkg6_intstr.IntOrString) } - yym591 := z.DecBinary() - _ = yym591 + yym592 := z.DecBinary() + _ = yym592 if false { } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { - } else if !yym591 && z.IsJSONHandle() { + } else if !yym592 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.MaxSurge) } else { z.DecFallback(x.MaxSurge, false) } } - yyj587++ - if yyhl587 { - yyb587 = yyj587 > l - } else { - yyb587 = r.CheckBreak() - } - if yyb587 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } for { - yyj587++ - if yyhl587 { - yyb587 = yyj587 > l + yyj588++ + if yyhl588 { + yyb588 = yyj588 > l } else { - yyb587 = r.CheckBreak() + yyb588 = r.CheckBreak() } - if yyb587 { + if yyb588 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj587-1, "") + z.DecStructFieldNotFound(yyj588-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -18447,7 +18447,7 @@ func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decode yyrg1522 := len(yyv1522) > 0 yyv21522 := yyv1522 - yyrl1522, yyrt1522 = z.DecInferLen(yyl1522, z.DecBasicHandle().MaxInitLen, 632) + yyrl1522, yyrt1522 = z.DecInferLen(yyl1522, z.DecBasicHandle().MaxInitLen, 640) if yyrt1522 { if yyrl1522 <= cap(yyv1522) { yyv1522 = yyv1522[:yyrl1522] diff --git a/pkg/apis/extensions/v1beta1/types.go b/pkg/apis/extensions/v1beta1/types.go index 0e1eec913e0..9a50c73978d 100644 --- a/pkg/apis/extensions/v1beta1/types.go +++ b/pkg/apis/extensions/v1beta1/types.go @@ -228,6 +228,11 @@ type DeploymentSpec struct { // The deployment strategy to use to replace existing pods with new ones. Strategy DeploymentStrategy `json:"strategy,omitempty"` + // Minimum number of seconds for which a newly created pod should be ready + // without any of its container crashing, for it to be considered available. + // Defaults to 0 (pod will be considered available as soon as it is ready) + MinReadySeconds int32 `json:"minReadySeconds,omitempty"` + // The number of old ReplicationControllers to retain to allow rollback. // This is a pointer to distinguish between explicit zero and not specified. RevisionHistoryLimit *int32 `json:"revisionHistoryLimit,omitempty"` @@ -322,11 +327,6 @@ type RollingUpdateDeployment struct { // new RC can be scaled up further, ensuring that total number of pods running // at any time during the update is atmost 130% of desired pods. MaxSurge *intstr.IntOrString `json:"maxSurge,omitempty"` - - // Minimum number of seconds for which a newly created pod should be ready - // without any of its container crashing, for it to be considered available. - // Defaults to 0 (pod will be considered available as soon as it is ready) - MinReadySeconds int32 `json:"minReadySeconds,omitempty"` } // DeploymentStatus is the most recently observed status of the Deployment. diff --git a/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go b/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go index 4687f64101c..831f7781197 100644 --- a/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go +++ b/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go @@ -184,6 +184,7 @@ var map_DeploymentSpec = map[string]string{ "selector": "Label selector for pods. Existing ReplicationControllers whose pods are selected by this will be the ones affected by this deployment.", "template": "Template describes the pods that will be created.", "strategy": "The deployment strategy to use to replace existing pods with new ones.", + "minReadySeconds": "Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready)", "revisionHistoryLimit": "The number of old ReplicationControllers to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified.", "uniqueLabelKey": "Key of the selector that is added to existing RCs (and label key that is added to its pods) to prevent the existing RCs to select new pods (and old pods being selected by new RC). Users can set this to an empty string to indicate that the system should not add any selector and label. If unspecified, system uses DefaultDeploymentUniqueLabelKey(\"deployment.kubernetes.io/podTemplateHash\"). Value of this key is hash of DeploymentSpec.PodTemplateSpec. No label is added if this is set to empty string.", "paused": "Indicates that the deployment is paused and will not be processed by the deployment controller.", @@ -532,10 +533,9 @@ func (RollingUpdateDaemonSet) SwaggerDoc() map[string]string { } var map_RollingUpdateDeployment = map[string]string{ - "": "Spec to control the desired behavior of rolling update.", - "maxUnavailable": "The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding up. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods.", - "maxSurge": "The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. By default, a value of 1 is used. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods.", - "minReadySeconds": "Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready)", + "": "Spec to control the desired behavior of rolling update.", + "maxUnavailable": "The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding up. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods.", + "maxSurge": "The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. By default, a value of 1 is used. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods.", } func (RollingUpdateDeployment) SwaggerDoc() map[string]string { diff --git a/pkg/apis/extensions/validation/validation.go b/pkg/apis/extensions/validation/validation.go index 5ef47b9012b..b49466f5856 100644 --- a/pkg/apis/extensions/validation/validation.go +++ b/pkg/apis/extensions/validation/validation.go @@ -290,7 +290,6 @@ func ValidateRollingUpdateDeployment(rollingUpdate *extensions.RollingUpdateDepl } // Validate that MaxUnavailable is not more than 100%. allErrs = append(allErrs, IsNotMoreThan100Percent(rollingUpdate.MaxUnavailable, fldPath.Child("maxUnavailable"))...) - allErrs = append(allErrs, apivalidation.ValidateNonnegativeField(int64(rollingUpdate.MinReadySeconds), fldPath.Child("minReadySeconds"))...) return allErrs } @@ -322,6 +321,7 @@ func ValidateDeploymentSpec(spec *extensions.DeploymentSpec, fldPath *field.Path allErrs = append(allErrs, apivalidation.ValidateNonnegativeField(int64(spec.Replicas), fldPath.Child("replicas"))...) allErrs = append(allErrs, apivalidation.ValidatePodTemplateSpecForRC(&spec.Template, spec.Selector, spec.Replicas, fldPath.Child("template"))...) allErrs = append(allErrs, ValidateDeploymentStrategy(&spec.Strategy, fldPath.Child("strategy"))...) + allErrs = append(allErrs, apivalidation.ValidateNonnegativeField(int64(spec.MinReadySeconds), fldPath.Child("minReadySeconds"))...) if spec.RevisionHistoryLimit != nil { // zero is a valid RevisionHistoryLimit allErrs = append(allErrs, apivalidation.ValidateNonnegativeField(int64(*spec.RevisionHistoryLimit), fldPath.Child("revisionHistoryLimit"))...) diff --git a/pkg/controller/deployment/deployment_controller.go b/pkg/controller/deployment/deployment_controller.go index 7b2a776a4e2..c2d2679603a 100644 --- a/pkg/controller/deployment/deployment_controller.go +++ b/pkg/controller/deployment/deployment_controller.go @@ -799,7 +799,7 @@ func (dc *DeploymentController) reconcileOldRCs(allRCs []*api.ReplicationControl } // Check if we can scale down. minAvailable := deployment.Spec.Replicas - maxUnavailable - minReadySeconds := deployment.Spec.Strategy.RollingUpdate.MinReadySeconds + minReadySeconds := deployment.Spec.MinReadySeconds // Check the expectations of deployment before counting available pods dKey, err := controller.KeyFunc(&deployment) if err != nil { @@ -923,10 +923,7 @@ func (dc *DeploymentController) updateDeploymentStatus(allRCs []*api.Replication func (dc *DeploymentController) calculateStatus(allRCs []*api.ReplicationController, newRC *api.ReplicationController, deployment extensions.Deployment) (totalReplicas, updatedReplicas, availableReplicas, unavailableReplicas int, err error) { totalReplicas = deploymentutil.GetReplicaCountForRCs(allRCs) updatedReplicas = deploymentutil.GetReplicaCountForRCs([]*api.ReplicationController{newRC}) - minReadySeconds := 0 - if deployment.Spec.Strategy.Type == extensions.RollingUpdateDeploymentStrategyType { - minReadySeconds = deployment.Spec.Strategy.RollingUpdate.MinReadySeconds - } + minReadySeconds := deployment.Spec.MinReadySeconds availableReplicas, err = deploymentutil.GetAvailablePodsForRCs(dc.client, allRCs, minReadySeconds) if err != nil { err = fmt.Errorf("failed to count available pods: %v", err) diff --git a/pkg/kubectl/describe.go b/pkg/kubectl/describe.go index 7984b1dccac..4525264a534 100644 --- a/pkg/kubectl/describe.go +++ b/pkg/kubectl/describe.go @@ -1604,9 +1604,10 @@ func (dd *DeploymentDescriber) Describe(namespace, name string) (string, error) fmt.Fprintf(out, "Selector:\t%s\n", labels.FormatLabels(d.Spec.Selector)) fmt.Fprintf(out, "Replicas:\t%d updated | %d total | %d available | %d unavailable\n", d.Status.UpdatedReplicas, d.Spec.Replicas, d.Status.AvailableReplicas, d.Status.UnavailableReplicas) fmt.Fprintf(out, "StrategyType:\t%s\n", d.Spec.Strategy.Type) + fmt.Fprintf(out, "MinReadySeconds:\t%s\n", d.Spec.MinReadySeconds) if d.Spec.Strategy.RollingUpdate != nil { ru := d.Spec.Strategy.RollingUpdate - fmt.Fprintf(out, "RollingUpdateStrategy:\t%s max unavailable, %s max surge, %d min ready seconds\n", ru.MaxUnavailable.String(), ru.MaxSurge.String(), ru.MinReadySeconds) + fmt.Fprintf(out, "RollingUpdateStrategy:\t%s max unavailable, %s max surge\n", ru.MaxUnavailable.String(), ru.MaxSurge.String()) } oldRCs, _, err := deploymentutil.GetOldRCs(*d, dd) if err == nil { diff --git a/test/e2e/deployment.go b/test/e2e/deployment.go index 1dc155875ff..3fa4627e251 100644 --- a/test/e2e/deployment.go +++ b/test/e2e/deployment.go @@ -471,10 +471,10 @@ func testRolloverDeployment(f *Framework) { deploymentStrategyType := extensions.RollingUpdateDeploymentStrategyType Logf("Creating deployment %s", deploymentName) newDeployment := newDeployment(deploymentName, deploymentReplicas, deploymentPodLabels, deploymentImageName, deploymentImage, deploymentStrategyType, nil) + newDeployment.Spec.MinReadySeconds = deploymentMinReadySeconds newDeployment.Spec.Strategy.RollingUpdate = &extensions.RollingUpdateDeployment{ - MaxUnavailable: intstr.FromInt(1), - MaxSurge: intstr.FromInt(1), - MinReadySeconds: deploymentMinReadySeconds, + MaxUnavailable: intstr.FromInt(1), + MaxSurge: intstr.FromInt(1), } _, err = c.Extensions().Deployments(ns).Create(newDeployment) Expect(err).NotTo(HaveOccurred())