Closed dwasse closed 2 weeks ago
[!WARNING]
Review failed
The pull request is closed.
The recent updates streamline concurrency handling by replacing errgroup.Group
with sync.WaitGroup
in chainQueue
and improve logic for relaying acknowledgments in QuoterAPIServer
. New methods for handling database updates, retry mechanisms, and synchronization have been introduced across various files, enhancing efficiency and robustness of the service.
File/Path | Change Summary |
---|---|
ethergo/submitter/chain_queue.go |
Swapped errgroup.Group with sync.WaitGroup and refined error handling in bumpTX and updateOldTxStatuses . |
services/rfq/api/rest/server.go |
Modified PutRelayAck to include address comparison for acknowledgment relay decision. |
services/rfq/api/rest/server_test.go |
Adjusted TestPutAck to expect ShouldRelay as true . |
services/rfq/relayer/quoter/quoter.go |
Introduced parallel address screening using errgroup.WithContext . |
services/rfq/relayer/reldb/base/model.go |
Added RelayNonce field and updated related functions. |
services/rfq/relayer/reldb/base/quote.go |
Added UpdateRelayNonce function to Store struct. |
services/rfq/relayer/reldb/base/rebalance.go |
Introduced GetDBStats function to retrieve database statistics. |
services/rfq/relayer/reldb/db.go |
Added methods for updating relay nonce and retrieving DB stats in Writer and Reader interfaces. |
services/rfq/relayer/reldb/mysql/mysql.go |
Reordered imports, moving time below existing imports. |
services/rfq/relayer/service/handlers.go |
Added retry logic, error handling improvements, and synchronization for handling requests. |
services/rfq/relayer/service/relayer.go |
Introduced synchronization mechanisms and semaphores to manage concurrent request processing. |
services/rfq/relayer/service/statushandler.go |
Added mutexMiddlewareFunc and a new Forward method for forwarding quote requests. |
In lines of sync and waiting queue, A world of code, serene and true, Requests in tandem, errors abate, With nonce updates, we innovate.
Through hoops and retries, they dance, New features rise, a joyful chance, 🐇 Code refined, robust and grand, Together now, we make our stand. 🌟
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Summary by CodeRabbit
New Features
Forward
method for quote requests inQuoteRequestHandler
.Improvements
errgroup.Group
withsync.WaitGroup
for more efficient task management.