[ISSUE #10962] Fix lite subscription quota validation for remove actions - #10963
[ISSUE #10962] Fix lite subscription quota validation for remove actions#10963yx9o wants to merge 1 commit into
Conversation
yx9o
commented
Aug 24, 2026
- Fixes [Enhancement] Improve Lite subscription quota validation for remove actions #10962 .
RockteMQ-AI
left a comment
There was a problem hiding this comment.
Summary
This PR fixes a bug where validateLiteSubscriptionQuota was called for all lite subscription actions, including REMOVE operations. The fix correctly restricts quota validation to only ADD-type actions (PARTIAL_ADD, COMPLETE_ADD), since removing subscriptions frees quota rather than consuming it. The change is small, focused, and includes test coverage for the PARTIAL_REMOVE case. LGTM.
Automated review by github-manager-bot
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #10963 +/- ##
=============================================
- Coverage 48.58% 48.52% -0.06%
+ Complexity 13671 13656 -15
=============================================
Files 1381 1381
Lines 101475 101478 +3
Branches 13189 13190 +1
=============================================
- Hits 49302 49244 -58
- Misses 46176 46219 +43
- Partials 5997 6015 +18 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
RockteMQ-AI
left a comment
There was a problem hiding this comment.
Summary
Fixes quota validation being incorrectly applied to remove/unsubscribe actions in lite subscription sync. The validation should only gate additive operations (PARTIAL_ADD, COMPLETE_ADD), not removals.
Review
- Correctness ✅ — The
shouldValidateLiteSubscriptionQuota()guard correctly restricts quota checks to add actions only. Remove actions should never be blocked by quota limits. - Code quality ✅ — Clean extraction of the condition into a private method improves readability. The local variable
actionavoids repeatedgetAction()calls. - Tests ✅ — Test coverage added for the remove action path.
LGTM — straightforward and correct fix.
Automated review by github-manager-bot