-
Notifications
You must be signed in to change notification settings - Fork 26
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: Clear the queue before adding new elements #439
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #439 +/- ##
=========================================
Coverage 90.75% 90.76%
Complexity 489 489
=========================================
Files 47 47
Lines 1731 1732 +1
Branches 207 207
=========================================
+ Hits 1571 1572 +1
Misses 97 97
Partials 63 63 ☔ View full report in Codecov by Sentry. |
Signed-off-by: Oleg Kopysov <[email protected]>
@@ -147,6 +147,7 @@ public BlockingDeque<LPVSQueue> getQueue() { | |||
* @throws InterruptedException If interrupted while processing the queue. | |||
*/ | |||
public void checkForQueue() throws InterruptedException { | |||
QUEUE.clear(); |
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.
As an option, I'd pur warning here if queue is not clear. Cause we should pay attention, some webhooks are not processed.
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.
I don't think that warning is needed here. This is the normal operation of the LPVS queue.
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.
Approved.
Pull Request
Description
The queue needs to be cleared before adding new elements.
Type of change
Please delete options that are not relevant.
Testing
Test Configuration:
Checklist: