-
Notifications
You must be signed in to change notification settings - Fork 33
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
Add Retry #28
base: master
Are you sure you want to change the base?
Conversation
@codelingo review |
Running fresh review. |
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.
2 issues found.
delay = 10 * time.Second | ||
} | ||
select { | ||
case <-time.After(delay): |
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.
Make one ticker as opposed to making a new timer each iteration.
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.
@codelingo It'd be helpful if the comment explained a bit more of the why here: you're essentially avoiding a mem leak as a new timer object is created on each iteration.
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.
Reply added to rule discussion thread
delay = 10 * time.Second | ||
} | ||
select { | ||
case <-time.After(delay): |
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.
Make one ticker as opposed to making a new timer each iteration.
No description provided.