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

Faulty move of reference count of shared rmqClient #1018

Closed
wgdzlh opened this issue Mar 31, 2023 · 0 comments · Fixed by #1019
Closed

Faulty move of reference count of shared rmqClient #1018

wgdzlh opened this issue Mar 31, 2023 · 0 comments · Fixed by #1019

Comments

@wgdzlh
Copy link
Contributor

wgdzlh commented Mar 31, 2023

#888 change reference count of shared rmqClient into sync.Once body, which is buggy. The client will be shutdown once any consumer or producer call Shutdown, but it may be still used by other consumer or producer.
The problem mentioned in #888 will not happen, since the start of client is called in sync.Once:

err = pc.defaultConsumer.start()

dc.client.Start()
, so it will only be called once. Multiple start call will not affect the reference count of client.
Simply revert #888 will fix the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant