feat: add multiple handlers support to TriggerProcessorService#132
Merged
LeonardoVieira1630 merged 43 commits intoSep 3, 2025
Conversation
Member
LeonardoVieira1630
commented
Aug 28, 2025
- Change triggerHandlers to support arrays of handlers per trigger ID
- Implement parallel execution of handlers using Promise.allSettled
- Add result aggregation combining messageIds and using latest timestamp
- Add fault-tolerant error handling that logs failures but doesn't break service
- Throw error only when all handlers fail
- Add comprehensive tests for multiple handler scenarios
- Change triggerHandlers to support arrays of handlers per trigger ID - Implement parallel execution of handlers using Promise.allSettled - Add result aggregation combining messageIds and using latest timestamp - Add fault-tolerant error handling that logs failures but doesn't break service - Throw error only when all handlers fail - Add comprehensive tests for multiple handler scenarios 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Replace multiple parallel getWalletOwners calls with single getWalletOwnersBatch call - Replace multiple shouldSend calls with single shouldSendBatch call - Reduce API requests from O(n) to O(1) for n addresses and events - Improve notification deduplication efficiency using batch operations - Maintain same notification logic while significantly reducing network overhead 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add getWalletOwnersBatch mock method to SubscriptionClient test mocks - Add shouldSendBatch mock method to SubscriptionClient test mocks - Ensure test files compile with new batch method signatures - Maintain test coverage for refactored batch processing functionality 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
lgahdl
approved these changes
Aug 28, 2025
…ting_power_messages Feat/add transaction link to voting power messages
- Modified Consumer App constructor to accept ENS resolver as parameter - Updated index.ts to create and inject ENS resolver instance - Enables easier testing by allowing mock injection This change prepares the codebase for using mock ENS resolver in tests to avoid async operations that continue after test teardown. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Created MockEnsResolverService that returns synchronous responses - Avoids real network calls to ENS during tests - Prevents async operations from continuing after test teardown This mock resolves the issue where ENS resolution was causing "import after Jest teardown" errors in integration tests. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Updated startTestApps to use MockEnsResolverService - Fixed tsconfig to exclude test files from build - Ensures all integration tests use mock instead of real ENS This completes the fix for voting-power test interference issue. All tests now pass consistently without async ENS operations. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Feat/non voting trigger
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.