Exclude duplicated votes #62
No reviewers
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
backmeupplz/banofbot!62
Loading…
Reference in a new issue
No description provided.
Delete branch "issue-61_duplicated_votes"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Exclude semaphore, like potential bottleneck, added use of a mongo addToSet instead of a push
@backmeupplz Let me explain what I did here. Point about addToSet we discussed in issue.
Logic with semaphore was removed because in current implementation it doesn't work as expected- for each processed request will create new semaphore, but for correct work- should be only one object. Like a fix - we can create one semaphore object outside of function scope. But in his case we will have bottleneck, because all requests will process one by one, which means that response time will be significantly longer. That's why semaphore was removed and rewrite push to addToSet.
PR temporary in draft because we want to test solution.
Pull request closed