kd icon indicating copy to clipboard operation
kd copied to clipboard

Don't block waiting for individual deployments

Open daniel-ac-martin opened this issue 6 years ago • 5 comments

Waits until all resources have been created / updated before checking the roll-out of a deployment. This way it is possible to deploy quicker as deployments can roll-out parallel to one another.

Addresses #82.

daniel-ac-martin avatar Jun 12 '18 14:06 daniel-ac-martin

@marcinc: The PR doesn't actually skip the watching it just defers it until the rest of the Kubernetes resources in a multi-resource YAML file have been created / updated.

daniel-ac-martin avatar Jun 18 '18 11:06 daniel-ac-martin

hi @daniel-ac-martin, I like the feature but do kinda agree with @marcinc .. It fundamentally changes deployment behavior and should be gated with a flag .. You go even go the full hog and thread the watchResource .. or perhaps another PR

gambol99 avatar Jun 19 '18 09:06 gambol99

Okay. Well I can add a flag if you like. But it's worth pointing out that supporting both behaviours will complicate the code a little.

In terms of changing the deployment behaviour it's worth bearing in mind that it wasn't too long ago that multi-resource YAML files didn't support watching. Are many people using multi-resource YAML files?

If we do add a flag it also raises the question of what the default behaviour should be?

daniel-ac-martin avatar Jun 19 '18 09:06 daniel-ac-martin

hey @daniel-ac-martin ... maybe i'm misreading the code but from a glance ...

  • building a list of files https://github.com/UKHomeOffice/kd/pull/83/files#diff-7ddfb3e035b42cd70649cc33393fe32cL154
  • reading and rendering each of those files in to []resources https://github.com/UKHomeOffice/kd/pull/83/files#diff-7ddfb3e035b42cd70649cc33393fe32cL174
  • and deploying each of the []resources https://github.com/UKHomeOffice/kd/pull/83/files#diff-7ddfb3e035b42cd70649cc33393fe32cL192

throwing aside the yaml splitting .. if I have/had multiple deployments all of them are going to be deployed in one iteration and checked afterwards ... rather than before which was deploy and check, deploy and check .. etc which is a pretty big change

gambol99 avatar Jun 19 '18 10:06 gambol99

Ah, I didn't think about multiple files being deployed at once. (Didn't know that was supported!)

daniel-ac-martin avatar Jun 19 '18 14:06 daniel-ac-martin