Skip to content
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

Update base rate for enabled swaps from uniswap each block #6513

Open
2 tasks
palango opened this issue Sep 7, 2020 · 1 comment
Open
2 tasks

Update base rate for enabled swaps from uniswap each block #6513

palango opened this issue Sep 7, 2020 · 1 comment

Comments

@palango
Copy link
Contributor

palango commented Sep 7, 2020

Sub-issue for #6506

Description

If token swaps are enabled, the node needs up-to-date information about swapping rates. Therefore it needs to update the base rates each time a new block is received.

Tasks

  • Implement efficient (if possible batched) request to fetch latest base rates
    • If possible design an interface that make using different oracles later easy
  • Only query the currently enables token pairs to lower load on the ethereum nodes.
@karlb
Copy link
Contributor

karlb commented Sep 10, 2020

We could also fetch the rate during the mediation. This would vastly reduce the number of calls and should be still acceptable from a latency perspective.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants