Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix(exp-engine): use new Waiter API
Signed-off-by: Ilya Lesikov <ilya@lesikov.com>
  • Loading branch information
ilya-lesikov committed Jul 21, 2023
1 parent 9814ed4 commit 3361a3d
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
7 changes: 5 additions & 2 deletions cmd/werf/converge/converge.go
Expand Up @@ -556,7 +556,11 @@ func run(ctx context.Context, containerBackend container_backend.ContainerBacken
return fmt.Errorf("error initializing deferred kube client: %w", err)
}

waiter := resourcewaiter.NewResourceWaiter(deferredKubeClient.Dynamic(), deferredKubeClient.Mapper())
trackTimeout := *common.NewDuration(time.Duration(cmdData.Timeout) * time.Second)
waiter := resourcewaiter.NewResourceWaiter(deferredKubeClient.Dynamic(), deferredKubeClient.Mapper(), resourcewaiter.NewResourceWaiterOptions{
Logger: logger,
DefaultTrackTimeout: trackTimeout,
})

statusProgressPeriod := time.Duration(*commonCmdData.StatusProgressPeriodSeconds) * time.Second
hooksStatusProgressPeriod := time.Duration(*commonCmdData.HooksStatusProgressPeriodSeconds) * time.Second
Expand All @@ -571,7 +575,6 @@ func run(ctx context.Context, containerBackend container_backend.ContainerBacken
mutator.NewReplicasOnCreationMutator(),
mutator.NewReleaseMetadataMutator(releaseName, namespace),
)
trackTimeout := *common.NewDuration(time.Duration(cmdData.Timeout) * time.Second)
cli.SetDeletionTimeout(int(trackTimeout))

// FIXME(ilya-lesikov): move some of it out of lock release wrapper
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Expand Up @@ -347,6 +347,6 @@ replace (
github.com/helm/helm-2to3 => github.com/werf/3p-helm-2to3 v0.0.0-20230313155428-cf9dd655c0e3 // switch back to upstream when merged: https://github.com/helm/helm-2to3/pull/224
github.com/jaguilar/vt100 => github.com/tonistiigi/vt100 v0.0.0-20190402012908-ad4c4a574305 // upstream not maintained
github.com/maorfr/helm-plugin-utils => github.com/werf/3p-helm-plugin-utils v0.6.1-0.20230313152239-057595ce9d57 // switch back to upstream when merged: https://github.com/maorfr/helm-plugin-utils/pull/17
helm.sh/helm/v3 => github.com/werf/3p-helm/v3 v3.0.0-20230721124034-069d446f230a
helm.sh/helm/v3 => github.com/werf/3p-helm/v3 v3.0.0-20230721125930-595aa78112f5
k8s.io/helm => github.com/werf/helm v0.0.0-20210202111118-81e74d46da0f
)
4 changes: 2 additions & 2 deletions go.sum
Expand Up @@ -1740,8 +1740,8 @@ github.com/weppos/publicsuffix-go v0.5.0/go.mod h1:z3LCPQ38eedDQSwmsSRW4Y7t2L8Ln
github.com/weppos/publicsuffix-go v0.20.1-0.20221209102050-40d9c30084b3 h1:ypyhoprZWFzU0ydOBv3I5SS7/jLFJ+ujPAU+BD/EVFM=
github.com/werf/3p-helm-2to3 v0.0.0-20230313155428-cf9dd655c0e3 h1:pdKLiuiUoOFswc0HV6GX1+JHgP14HqE035xl2DQJi8A=
github.com/werf/3p-helm-2to3 v0.0.0-20230313155428-cf9dd655c0e3/go.mod h1:lTSQBLomjl67m4HQMbg3BHKWes3pOmjNBg8yygXYugk=
github.com/werf/3p-helm/v3 v3.0.0-20230721124034-069d446f230a h1:Rl/eBUlHoPqd0DQo4HXBo851ct/3JOW2fMA15I/2jBE=
github.com/werf/3p-helm/v3 v3.0.0-20230721124034-069d446f230a/go.mod h1:vH6ckglZT6mhJefVLbUM9759Zt/wQnqqRe0BY4jmmHM=
github.com/werf/3p-helm/v3 v3.0.0-20230721125930-595aa78112f5 h1:ABh2GLSHga60eCodqBlLPzy46qMFX3u3wNlUP7vIHbk=
github.com/werf/3p-helm/v3 v3.0.0-20230721125930-595aa78112f5/go.mod h1:vH6ckglZT6mhJefVLbUM9759Zt/wQnqqRe0BY4jmmHM=
github.com/werf/copy-recurse v0.2.7 h1:3FTOarbJ9uhFLi75oeUCioK9zxZwuV7o28kuUBPDZPM=
github.com/werf/copy-recurse v0.2.7/go.mod h1:6Ypb+qN+hRBJgoCgEkX1vpbqcQ+8q69BQ3hi8s8Y6Qc=
github.com/werf/helm v0.0.0-20210202111118-81e74d46da0f h1:81YscYTF9mmTf0ULOsCmm42YWQp+qWDzWi1HjWniZrg=
Expand Down

0 comments on commit 3361a3d

Please sign in to comment.