argoproj / argo-cd

Declarative Continuous Deployment for Kubernetes
https://argo-cd.readthedocs.io
Apache License 2.0
17.8k stars 5.44k forks source link

hydrator: short-circuit hydration on hydrator.metadata drySha #19592

Open crenshaw-dev opened 2 months ago

crenshaw-dev commented 2 months ago

Today the hydrator will re-run hydration even if the target dry SHA has already been hydrated.

We should add logic to commit.go to read hydrator.metadata in the target branch (if present). If the dry SHA in hydrator.metadata matches the one being hydrated, we should log, quit early, and return a success code.

jcy0308 commented 2 months ago

@crenshaw-dev Can I work on this issue?? I'll try my best!

crenshaw-dev commented 2 months ago

@jcy0308 go for it!