-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: resolve goroutine leak caused by
egroup.WithContext
The `egroup.WithContext` method initializes a goroutine pool of size 1000 every time it is called. Instead of reusing or cleaning up the pool after use, it creates a new one, leading to goroutine leaks. This issue caused excessive memory usage and eventually led to the service being killed. This commit replaces `egroup.WithContext` with `errgroup.Group`.
- Loading branch information
小滋润
committed
Nov 17, 2024
1 parent
d178bf5
commit 4781ee9
Showing
2 changed files
with
6 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters