argocd-image-updater icon indicating copy to clipboard operation
argocd-image-updater copied to clipboard

Write back git is slow

Open yuyuvn opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe. We using argocd image updater to sync our cluster, which will need to sync more than 100 namespace at a time.

Because of this lock, it will fetch and commit one by one and our concurrency won't have effect for speed this progress. https://github.com/argoproj-labs/argocd-image-updater/blob/master/pkg/argocd/update.go#L489

Each time argocd image updater run git fetch, it will take about 20~30s, some time it take 1 minute. 😇

-> it took years to finish one check in our environment.

Describe the solution you'd like The lock name should consider to include not just repoURL but targetRevision

Describe alternatives you've considered Try git fetch with --depth 1 may also help decrease fetch time for long history repo. https://github.com/argoproj-labs/argocd-image-updater/blob/a03f31915d71ae39f1c9ac5d7d4d1501d11d158b/ext/git/client.go#L330

yuyuvn avatar Aug 24 '22 14:08 yuyuvn