-
-
Notifications
You must be signed in to change notification settings - Fork 188
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
fix: 修复 component 的 stop 先于 start 的情况下,内存泄漏的问题 #308
base: develop
Are you sure you want to change the base?
fix: 修复 component 的 stop 先于 start 的情况下,内存泄漏的问题 #308
Conversation
WalkthroughThe updates primarily involve refactoring the initialization process of a Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
感谢您提出Pull Request,我会尽快Review。我会在1-2日内进行查看或者回复,如果遇到节假日可能会处理较慢,敬请谅解。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (3)
- client.go (1 hunks)
- component/notify/componet_notify.go (4 hunks)
- component/notify/componet_notify_test.go (3 hunks)
Additional comments not posted (7)
component/notify/componet_notify.go (3)
23-26
: Import changes enhance functionality and organization.
40-47
: ConstructorNewConfigComponent
improves modularity and maintainability.
77-78
: Addition of debug log enhances visibility and debuggability of the component.component/notify/componet_notify_test.go (3)
21-24
: Import changes are necessary for new test functionality.
110-110
: Change in instantiation pattern ensures consistency and proper testing of the new constructor.
126-150
: New test functionTestConfigComponent_Stop
directly addresses the PR's objective and enhances test coverage.client.go (1)
140-140
: Use of the new constructorNewConfigComponent
inStartWithConfig
properly integrates it into the client's startup process and follows best practices for asynchronous operations.
Pull Request Test Coverage Report for Build 9042692976Details
💛 - Coveralls |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
在什么场景下 stopstop 会快于 start? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
start 为携程启动:
stop 依赖于 channel 不为空:
在 stopstop 快于 start 情况下会出现泄漏
Summary by CodeRabbit