zeitgeist icon indicating copy to clipboard operation
zeitgeist copied to clipboard

Cache account ids?

Open maltekliemann opened this issue 2 years ago • 1 comments

Regarding account_id(), the treasury pallet's documentation says the following about into_sub_account:

This actually does computation. If you need to keep using it, then make sure you cache the value and only call this once. [link]

We use this type of account generation in grand fashion. Should we cache market/pool accounts and trade chain storage for computation time?

maltekliemann avatar May 21 '22 11:05 maltekliemann

Absolutely. Let's keep it a low priority for now because it is an optimizations that is not needed right now, but eventually will be.

sea212 avatar Jul 10 '22 14:07 sea212