-
Notifications
You must be signed in to change notification settings - Fork 80
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(request-queue): Update request queue locking docs #1322
Conversation
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.
Looks good, but the variable naming is a bit confusing, could you improve it?
const theFirstRequestLockedByClientOne = processingRequestsClientOne.items[0]; | ||
const requestLockedByClientOne = await requestQueueClientOne.getRequest( |
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.
The naming of these two variables is pretty confusing, I don't really know what's the difference between theFirstRequestLockedByClientOne
and requestLockedByClientOne
, especially by name. Could you come up with some better names?
const theFirstRequestLockedByClientOne = processingRequestsClientOne.items[0]; | ||
const requestLockedByClientOne = await requestQueueClientOne.getRequest( | ||
theFirstRequestLockedByClientOne.id, | ||
const wasTheClientTwoLockedSameRequest = !!processingRequestsClientTwo.items.find( |
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.
Here I'm also not sure what the varaible means, could you rename it, or explain better in the comment?
Co-authored-by: Michał Olender <[email protected]>
I made some changes in docs regarding the API changes.