Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Optimise updates based on confirmed transactions #746

Closed
reyraa opened this issue Sep 14, 2017 · 1 comment
Closed

Optimise updates based on confirmed transactions #746

reyraa opened this issue Sep 14, 2017 · 1 comment

Comments

@reyraa
Copy link
Contributor

reyraa commented Sep 14, 2017

Expected behaviour

We can create a function which iterates over transactions once, and accepts multiple filter functions in pipeline and returns the result once. this saves us from ending up to multiple redundant iterations over all the transactions with every beat of metronome.

Actual behaviour

Presently we filter transactions 3 times for 3 similar goals:

  • To get the list recent of transactions with vote type.
  • To get the list recent of transactions with register as delegate type.
  • To update the number of confirmations

Where all these happen

in store/middlewares/account.js

@slaweet
Copy link
Contributor

slaweet commented Oct 5, 2017

It turned out that it would add unnecessary complexity to the code, so we won't do this.

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

No branches or pull requests

3 participants