Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use singleflight to clone/update repository cache #5171

Merged
merged 1 commit into from
Sep 5, 2024

Conversation

Warashi
Copy link
Contributor

@Warashi Warashi commented Sep 2, 2024

What this PR does / why we need it:

I profiled goroutines with the debug/pprof/goroutine endpoint and noticed goroutines are waiting at the lockRepo method.

goroutines waiting at the lockRepo I triggered 50 deployments simultaneously, and 45 goroutines are waiting at the lockRepo method.
goroutine profile: total 367
35 @ 0x51358 0x65768 0x65745 0x86708 0xaabf4 0x89bb98 0x89bb45 0x89a0d4 0x1091c74 0x1090f0c 0x109073c 0x12a0ed4 0x17a5f84 0x17a27a4 0x8afa4
#	0x86707		sync.runtime_SemacquireMutex+0x27								/home/warashi/go/pkg/mod/golang.org/[email protected]/src/runtime/sema.go:77
#	0xaabf3		sync.(*Mutex).lockSlow+0x173									/home/warashi/go/pkg/mod/golang.org/[email protected]/src/sync/mutex.go:171
#	0x89bb97	sync.(*Mutex).Lock+0x1e7									/home/warashi/go/pkg/mod/golang.org/[email protected]/src/sync/mutex.go:90
#	0x89bb44	github.com/pipe-cd/pipecd/pkg/git.(*client).lockRepo+0x194					/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/git/client.go:263
#	0x89a0d3	github.com/pipe-cd/pipecd/pkg/git.(*client).Clone+0x473						/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/git/client.go:153
#	0x1091c73	github.com/pipe-cd/pipecd/pkg/app/piped/deploysource.(*gitSourceCloner).Clone+0x63		/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/deploysource/sourcecloner.go:59
#	0x1090f0b	github.com/pipe-cd/pipecd/pkg/app/piped/deploysource.(*provider).prepare+0x1eb			/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/deploysource/deploysource.go:146
#	0x109073b	github.com/pipe-cd/pipecd/pkg/app/piped/deploysource.(*provider).Get+0x15b			/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/deploysource/deploysource.go:92
#	0x12a0ed3	github.com/pipe-cd/pipecd/pkg/app/piped/planner/kubernetes.(*Planner).Plan+0x63			/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/planner/kubernetes/kubernetes.go:56
#	0x17a5f83	github.com/pipe-cd/pipecd/pkg/app/piped/controller.(*planner).Run+0xa33				/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/controller/planner.go:218
#	0x17a27a3	github.com/pipe-cd/pipecd/pkg/app/piped/controller.(*controller).startNewPlanner.func2+0x83	/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/controller/controller.go:497

...


10 @ 0x51358 0x65768 0x65745 0x86708 0xaabf4 0x89bb98 0x89bb45 0x89a0d4 0x1091c74 0x1090f0c 0x1090afc 0x17a922c 0x17a3fb4 0x8afa4
#	0x86707		sync.runtime_SemacquireMutex+0x27								/home/warashi/go/pkg/mod/golang.org/[email protected]/src/runtime/sema.go:77
#	0xaabf3		sync.(*Mutex).lockSlow+0x173									/home/warashi/go/pkg/mod/golang.org/[email protected]/src/sync/mutex.go:171
#	0x89bb97	sync.(*Mutex).Lock+0x1e7									/home/warashi/go/pkg/mod/golang.org/[email protected]/src/sync/mutex.go:90
#	0x89bb44	github.com/pipe-cd/pipecd/pkg/git.(*client).lockRepo+0x194					/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/git/client.go:263
#	0x89a0d3	github.com/pipe-cd/pipecd/pkg/git.(*client).Clone+0x473						/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/git/client.go:153
#	0x1091c73	github.com/pipe-cd/pipecd/pkg/app/piped/deploysource.(*gitSourceCloner).Clone+0x63		/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/deploysource/sourcecloner.go:59
#	0x1090f0b	github.com/pipe-cd/pipecd/pkg/app/piped/deploysource.(*provider).prepare+0x1eb			/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/deploysource/deploysource.go:146
#	0x1090afb	github.com/pipe-cd/pipecd/pkg/app/piped/deploysource.(*provider).GetReadOnly+0x15b		/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/deploysource/deploysource.go:116
#	0x17a922b	github.com/pipe-cd/pipecd/pkg/app/piped/controller.(*scheduler).Run+0x97b			/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/controller/scheduler.go:264
#	0x17a3fb3	github.com/pipe-cd/pipecd/pkg/app/piped/controller.(*controller).startNewScheduler.func2+0x83	/home/warashi/ghq/github.com/pipe-cd/pipecd/pkg/app/piped/controller/controller.go:646

...

The lock/unlock line is here.

pipecd/pkg/git/client.go

Lines 153 to 154 in a61c397

c.lockRepo(repoID)
defer c.unlockRepo(repoID)

The git clone/fetch operation is heavy, so we can put these in the singleflight, not guarding with the mutex.

I got the performance improvement on my local machine, about 10x 〜 20x faster when triggering 50 deployments simultaneously.

Which issue(s) this PR fixes:

Fixes #

Does this PR introduce a user-facing change?:

  • How are users affected by this change:
  • Is this breaking change:
  • How to migrate (if breaking change):

Copy link

codecov bot commented Sep 2, 2024

Codecov Report

Attention: Patch coverage is 60.78431% with 20 lines in your changes missing coverage. Please review.

Project coverage is 22.91%. Comparing base (a61c397) to head (44094ad).
Report is 35 commits behind head on master.

Files with missing lines Patch % Lines
pkg/git/client.go 60.78% 15 Missing and 5 partials ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master    #5171   +/-   ##
=======================================
  Coverage   22.90%   22.91%           
=======================================
  Files         416      416           
  Lines       44598    44604    +6     
=======================================
+ Hits        10216    10219    +3     
- Misses      33592    33594    +2     
- Partials      790      791    +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Comment on lines +156 to 200
_, err, _ := c.repoSingleFlights.Do(repoID, func() (interface{}, error) {
_, err := os.Stat(repoCachePath)
if err != nil && !os.IsNotExist(err) {
return nil, err
}
out, err := retryCommand(3, time.Second, logger, func() ([]byte, error) {
args := []string{"clone", "--mirror", remote, repoCachePath}
args = append(authArgs, args...)
return runGitCommand(ctx, c.gitPath, "", c.envsForRepo(remote), args...)
})
if err != nil {
logger.Error("failed to clone from remote",
zap.String("out", string(out)),
zap.Error(err),
)
return nil, fmt.Errorf("failed to clone from remote: %v", err)
}
} else {
// Cache hit. Do a git fetch to keep updated.
c.logger.Info(fmt.Sprintf("fetching %s to update the cache", repoID))
out, err := retryCommand(3, time.Second, c.logger, func() ([]byte, error) {
args := []string{"fetch"}
args = append(authArgs, args...)
return runGitCommand(ctx, c.gitPath, repoCachePath, c.envsForRepo(remote), args...)
})
if err != nil {
logger.Error("failed to fetch from remote",
zap.String("out", string(out)),
zap.Error(err),
)
return nil, fmt.Errorf("failed to fetch: %v", err)

if os.IsNotExist(err) {
// Cache miss, clone for the first time.
logger.Info(fmt.Sprintf("cloning %s for the first time", repoID))
if err := os.MkdirAll(filepath.Dir(repoCachePath), os.ModePerm); err != nil && !os.IsExist(err) {
return nil, err
}
out, err := retryCommand(3, time.Second, logger, func() ([]byte, error) {
args := []string{"clone", "--mirror", remote, repoCachePath}
args = append(authArgs, args...)
return runGitCommand(ctx, c.gitPath, "", c.envsForRepo(remote), args...)
})
if err != nil {
logger.Error("failed to clone from remote",
zap.String("out", string(out)),
zap.Error(err),
)
return nil, fmt.Errorf("failed to clone from remote: %v", err)
}
} else {
// Cache hit. Do a git fetch to keep updated.
c.logger.Info(fmt.Sprintf("fetching %s to update the cache", repoID))
out, err := retryCommand(3, time.Second, c.logger, func() ([]byte, error) {
args := []string{"fetch"}
args = append(authArgs, args...)
return runGitCommand(ctx, c.gitPath, repoCachePath, c.envsForRepo(remote), args...)
})
if err != nil {
logger.Error("failed to fetch from remote",
zap.String("out", string(out)),
zap.Error(err),
)
return nil, fmt.Errorf("failed to fetch: %v", err)
}
}
return nil, nil
})
if err != nil {
return nil, err
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[ask] If piped has already cloned the repo, then it hasn't fetched some updates?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In that case, piped do a git fetch at L186

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If so, we might consider the effect which piped doesn't fetch the repo at this point.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the cache doesn't exist, piped does git clone. Else, does git fetch.

Oops, are you considering the race condition such as the new updates are pushed after git fetch?

Copy link
Member

@ffjlabo ffjlabo Sep 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I expected that the code inside the singleflight.Do are executed at first call.
The scope of the singlefight seems from L156 to L197. So in my understanding, at first, singleflight.Do executes the method and clone successfully and recorded the result with the repoID. And the second time, singleflight.Do just return the recorded values, not execute the code inside the singleflight.Do.

Sorry if I misunderstood 🙏

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's the behavior of the sync.Once, not the singleflight.Do.
singleflight.Do treats only the duplicate calls that occur when the former call is in-flight.

https://pkg.go.dev/internal/singleflight#Group.Do

Do executes and returns the results of the given function, making sure that only one execution is in-flight for a given key at a time. If a duplicate comes in, the duplicate caller waits for the original to complete and receives the same results. The return value shared indicates whether v was given to multiple callers.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, I see. Thank you. I misunderstood the behavior.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It means that with one execution for sigleflight.Do, the goroutines executed at the same time can confirm one result.

Copy link
Member

@ffjlabo ffjlabo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!
Also if possible, we should describe the result of the pprof

@Warashi
Copy link
Contributor Author

Warashi commented Sep 3, 2024

Thank you.
I updated the PR description with the goroutines stack information.

@Warashi Warashi enabled auto-merge (squash) September 5, 2024 02:56
Copy link
Member

@khanhtc1202 khanhtc1202 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Greate improvement 👍

@Warashi Warashi merged commit 0f52877 into master Sep 5, 2024
17 checks passed
@Warashi Warashi deleted the singleflight-clone branch September 5, 2024 05:03
github-actions bot pushed a commit that referenced this pull request Sep 5, 2024
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: pipecd-bot <[email protected]>
@github-actions github-actions bot mentioned this pull request Sep 5, 2024
github-actions bot pushed a commit that referenced this pull request Sep 5, 2024
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: pipecd-bot <[email protected]>
ffjlabo added a commit that referenced this pull request Sep 5, 2024
* Modified to use Git with PAT (#4571)

* fix to read PAT settings from file

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* piped

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* include  PAT information in URL

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: modification of conditional branching

Co-authored-by: sivchari <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: corrected error in error message

Co-authored-by: sivchari <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: integration of mask function

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: make validation test

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: function name

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: rename function for validation PAT

Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: fix test code as pointed out in the review

Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* feat: add explan
for git personal access token in document

Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: change required in documentation

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: change return value

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: add test case

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: fix test

Signed-off-by: swallow <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: PipedGit struct to use password
authentication instead of personal access token

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix to read PAT settings from file

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* piped

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: integration of mask function

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: make validation test

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: function name

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: rename function for validation PAT

Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: fix test

Signed-off-by: swallow <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: PipedGit struct to use password
authentication instead of personal access token

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Fix Git authentication configuration

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Update password authentication configuration

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Fix error variable name

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Fix rename password

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Refactor includePasswordAuthRemote function

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Update password authentication in clone test

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: delete PasswordAuth

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: remove unused PasswordAuth field and refactor password authentication in git client

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Remove unnecessary print statement in Validate function

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: fix code for rebase

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* fix: remove unused GitPasswordAuth configuration

Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* feat: add password decoding for password in includePasswordRemote function

Signed-off-by: sZma5a <[email protected]>

* fix: refactor Git password authentication method

Signed-off-by: sZma5a <[email protected]>

* fix: update password encoding in TestCloneUsingPassword

Signed-off-by: sZma5a <[email protected]>

* Update docs/content/en/docs-dev/user-guide/managing-piped/configuration-reference.md

Co-authored-by: Yoshiki Fujikane <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* Update pkg/config/piped.go

Co-authored-by: Yoshiki Fujikane <[email protected]>
Signed-off-by: sZma5a <[email protected]>

* [wip] delete password

Signed-off-by: sZma5a <[email protected]>

* [wip] not tested - change token to args from url

Signed-off-by: sZma5a <[email protected]>

* Fix commented out test case

Signed-off-by: sZma5a <[email protected]>

* Refactor authentication in git client

Signed-off-by: sZma5a <[email protected]>

* feat: add password decoding function and replace Password string

Signed-off-by: sZma5a <[email protected]>

---------

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Co-authored-by: sZma5a <[email protected]>
Co-authored-by: sivchari <[email protected]>
Co-authored-by: 鈴木 優耀 <[email protected]>
Co-authored-by: Your Name <[email protected]>
Co-authored-by: Yoshiki Fujikane <[email protected]>
Signed-off-by: pipecd-bot <[email protected]>

* Use singleflight to clone/update repository cache (#5171)

Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: pipecd-bot <[email protected]>

* Refactor the git clone (#5190)

Move the authArgs into the singleflight closure, as they are only used within it.

Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Signed-off-by: pipecd-bot <[email protected]>

---------

Signed-off-by: sZma5a <[email protected]>
Signed-off-by: 鈴木 優耀 <[email protected]>
Signed-off-by: Your Name <[email protected]>
Signed-off-by: sZma5a <[email protected]>
Signed-off-by: swallow <[email protected]>
Signed-off-by: pipecd-bot <[email protected]>
Signed-off-by: Shinnosuke Sawada-Dazai <[email protected]>
Co-authored-by: sZma5a <[email protected]>
Co-authored-by: sZma5a <[email protected]>
Co-authored-by: sivchari <[email protected]>
Co-authored-by: 鈴木 優耀 <[email protected]>
Co-authored-by: Your Name <[email protected]>
Co-authored-by: Yoshiki Fujikane <[email protected]>
Co-authored-by: Shinnosuke Sawada-Dazai <[email protected]>
@github-actions github-actions bot mentioned this pull request Sep 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants