-
Notifications
You must be signed in to change notification settings - Fork 354
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
backend: list message concurrent stream send fix #1076
backend: list message concurrent stream send fix #1076
Conversation
timeout = 31 * time.Minute | ||
} | ||
|
||
ctx, cancel := context.WithTimeoutCause(ctx, timeout, errors.New("list fetch timeout")) |
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.
Very good to add the reason there 👍
if message == nil { | ||
return | ||
} |
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.
Wondering why this is necessary? When would we send nil here?
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.
it was just a guard I added as I was debugging. we really shouldn't but might be a good idea.
Multiple goroutines may perform writes (stream
Send()
s) to the stream via stream reporter. In stream reporter ensure these are guarded using a mutex.Minor frontend cleanup to only have a single Console service client.
Fixes #1073.