-
Notifications
You must be signed in to change notification settings - Fork 2
webhook metadata #15
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
webhook metadata #15
Conversation
Caution Review failedThe pull request is closed. WalkthroughThis set of changes introduces a new EOA (Externally Owned Account) transaction executor with robust error handling, nonce management, and crash recovery. Documentation is updated and expanded, including a detailed new architecture overview. The webhook system now supports user-provided metadata, and error handling in the EOA worker is refactored for explicitness and resilience. Changes
Sequence Diagram(s)sequenceDiagram
participant Scheduler
participant EOAWorker
participant RedisStore
participant Blockchain
participant Webhook
Scheduler->>EOAWorker: Start job for EOA:Chain
EOAWorker->>RedisStore: Acquire lock
alt Lock acquired
EOAWorker->>RedisStore: Recover borrowed txs (crash recovery)
EOAWorker->>Blockchain: Confirm mined/failed txs (confirmation phase)
EOAWorker->>RedisStore: Update tx state, recycle nonces if needed
EOAWorker->>Blockchain: Send new txs (send phase)
alt Insufficient funds
EOAWorker->>Scheduler: Return EoaOutOfFunds error (Nack, delay)
else Success
EOAWorker->>RedisStore: Update state
EOAWorker->>Webhook: Queue notification (with user_metadata)
end
EOAWorker->>RedisStore: Release lock
else Lock not acquired
Scheduler->>EOAWorker: Retry later
end
sequenceDiagram
participant User
participant System
participant Webhook
User->>System: Submit transaction with user_metadata
System->>System: Store user_metadata in WebhookOptions
System->>Webhook: Send notification with user_metadata
sequenceDiagram
participant EOAWorker
participant Scheduler
EOAWorker->>Scheduler: Encounter EoaOutOfFunds error
Scheduler->>EOAWorker: Nack with 60s delay, requeue last
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 Clippy (1.86.0)
error: failed to get Caused by: Caused by: Caused by: Caused by: 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (13)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Summary by CodeRabbit
New Features
Bug Fixes
Documentation
Refactor
Tests
Style
Chores