interledgerjs / ilp-plugin-ethereum

Settle Interledger payments with ETH and ERC-20 tokens

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Limit incoming queue to a single claim

kincaidoneil opened this issue · comments

On a T04 errors, the plugin sends the latest claim to the peer. Often, this requires verifying the signature, which if many T04s are triggered, can overwhelm the plugin/connector.

Alternatively, only allow a single validate claim task in the queue, and if a new one is enqueued, drop any others without running them.

Also, one simple heuristic to use that could improve performance: if the signature in the new claim is the same as the existing claim, don't do anything!