Skip queueing duplicate certificate generation event#10942
Skip queueing duplicate certificate generation event#10942
Conversation
📝 WalkthroughWalkthroughThe guard condition in Update::action (Verification/Update) was changed to short-circuit not only when a rule is already verified but also when its status is 'verifying'. A comment explaining the added condition was added above the check to clarify intent and prevent re-queuing during ongoing certificate generation. Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Areas requiring attention:
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (9)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Security Scan Results for PRDocker Image Scan Results
Source Code Scan Results🎉 No vulnerabilities found! |
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
src/Appwrite/Platform/Modules/Proxy/Http/Rules/Verification/Update.php (1)
132-135: Extract rule status values to shared constantsThe 'verifying' status is used as a raw string literal across multiple files in the proxy rules module (Update.php, Site/Create.php, Redirect/Create.php, Function/Create.php, API/Create.php). Without a centralized constant, there's risk of inconsistency if the status name changes or if new code introduces typos. Create a status constants class (e.g.,
RuleStatuswithconst VERIFYING = 'verifying') and wire it throughout the proxy rules module.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
src/Appwrite/Platform/Modules/Proxy/Http/Rules/Verification/Update.php(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: Setup & Build Appwrite Image
- GitHub Check: Setup & Build Appwrite Image
- GitHub Check: scan
🔇 Additional comments (1)
src/Appwrite/Platform/Modules/Proxy/Http/Rules/Verification/Update.php (1)
132-135: The early-return guard is appropriate. Thefinallyblock at line 225 ensuressaveCertificateDocumentalways executes and updates the rule status to either'verified'or'unverified', even if the certificate job fails. Status will never remain stuck in'verifying'after the worker completes. The'verification'attribute check appears unused (never set totrueanywhere in the codebase). No additional stale-timeout or force-retry mechanism is needed.
✨ Benchmark results
⚡ Benchmark Comparison
|
|
Superseded by #10962 |
Related SER-287